/* Stripping the explicit protocol prefix may result in a protocol
* prefix being (wrongly) detected (if the filename contains a colon) */
if (path_has_protocol(filename)) {
- QString *fat_filename;
+ GString *fat_filename;
/* This means there is some colon before the first slash; therefore,
* this cannot be an absolute path */
/* And we can thus fix the protocol detection issue by prefixing it
* by "./" */
- fat_filename = qstring_from_str("./");
- qstring_append(fat_filename, filename);
+ fat_filename = g_string_new("./");
+ g_string_append(fat_filename, filename);
- assert(!path_has_protocol(qstring_get_str(fat_filename)));
+ assert(!path_has_protocol(fat_filename->str));
- qdict_put(options, "filename", fat_filename);
+ qdict_put(options, "filename",
+ qstring_from_gstring(fat_filename));
} else {
/* If no protocol prefix was detected, we can use the shortened
* filename as-is */