failtest: Change mode_t to int.
authorAndreas Schlick <schlick@lavabit.com>
Sat, 2 Apr 2011 01:13:52 +0000 (11:43 +1030)
committerRusty Russell <rusty@rustcorp.com.au>
Sat, 2 Apr 2011 01:13:52 +0000 (11:43 +1030)
This avoids a warning on systems that have a 16bit wide mode_t.

ccan/failtest/failtest.c

index 851f2eabf043e4e3f8fa8c53cfe2056431a27220..061d6e9e3fc911c12c88fe7b122a417287441133 100644 (file)
@@ -677,7 +677,7 @@ int failtest_open(const char *pathname,
        va_start(ap, line);
        call.flags = va_arg(ap, int);
        if (call.flags & O_CREAT) {
-               call.mode = va_arg(ap, mode_t);
+               call.mode = va_arg(ap, int);
                va_end(ap);
        }
        p = add_history(FAILTEST_OPEN, file, line, &call);