summary refs log tree commit diff
path: root/pkgs/development/libraries/glib/darwin-compilation.patch
blob: f215eef798af9b10fb3b04c27512dcb5d835c8d3 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
Fix compilation on Mac OS X with gcc 4.8.

diff -ru glib-2.40.0-orig/gio/gdummyfile.c glib-2.40.0/gio/gdummyfile.c
--- glib-2.40.0-orig/gio/gdummyfile.c   2014-02-03 18:40:41.000000000 +0100
+++ glib-2.40.0/gio/gdummyfile.c        2014-07-15 10:58:31.000000000 +0200
@@ -454,7 +454,8 @@
   result = g_malloc (escaped_string_end - escaped_string + 1);
        
   out = result;
-  for (in = escaped_string; in < escaped_string_end; in++) 
+  in = escaped_string;
+  for (; in < escaped_string_end; in++) 
     {
       character = *in;
       if (*in == '%') 
@@ -551,6 +552,7 @@
   
   decoded->scheme = g_malloc (p - uri);
   out = decoded->scheme;
-  for (in = uri; in < p - 1; in++)
+  in = uri;
+  for (; in < p - 1; in++)
     *out++ = g_ascii_tolower (*in);
   *out = 0;