Compiling current SVN fails with the following error for me:
authorThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Tue, 2 Dec 2008 22:26:00 +0000 (22:26 -0000)
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Tue, 2 Dec 2008 22:26:00 +0000 (22:26 -0000)
 cc1: warnings being treated as errors
 buildroot/buildroot/build_powerpc/makedevs/makedevs.c: In function main:
 buildroot/buildroot/build_powerpc/makedevs/makedevs.c:531: error:
 ignoring return value of system, declared with attribute warn_unused_result

This change adds a simple warning if system() fails.

Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
target/makedevs/makedevs.c

index 8fa3048c473e65afd020c8b3cc8a4030b713d161..5ca45e9aeb422e487c569aefe24e1591ee93cfda 100644 (file)
@@ -528,7 +528,8 @@ loop:
        }
        fclose(table);
 
-       system("/bin/sync");
+       if (system("/bin/sync"))
+               bb_error_msg("sync failed, continuing anyway");
 
        return 0;
 }