66 + if (!new_mimes) 67 { 68 gchar *empty[] = {NULL}; 69 - 70 - mimes = g_strdupv (empty); 71 + mimes = empty; 72 }
Ouch, looks pretty dangerous, you're taking address of a temporary that's not valid outside of that block.
181 + for (it = mimes; *it; it++) 182 + { 183 + g_variant_builder_add (&b, "s", *it); 184 + }
Why so complicated? How about g_variant_new_strv()? (or perhaps `g_variant_new("(@as)", g_variant_new_strv(...));`)
« Back to merge proposal
66 + if (!new_mimes)
67 {
68 gchar *empty[] = {NULL};
69 -
70 - mimes = g_strdupv (empty);
71 + mimes = empty;
72 }
Ouch, looks pretty dangerous, you're taking address of a temporary that's not valid outside of that block.
181 + for (it = mimes; *it; it++) builder_ add (&b, "s", *it);
182 + {
183 + g_variant_
184 + }
Why so complicated? How about g_variant_ new_strv( )? (or perhaps `g_variant_ new("(@ as)", g_variant_ new_strv( ...));` )