]> xenbits.xensource.com Git - people/liuw/rumprun.git/commitdiff
Revert "return correct value from -1/errno stub"
authorAntti Kantee <pooka@iki.fi>
Mon, 20 Apr 2015 22:34:43 +0000 (22:34 +0000)
committerAntti Kantee <pooka@iki.fi>
Mon, 20 Apr 2015 22:34:43 +0000 (22:34 +0000)
This reverts commit fac52c22a17e07e5000283f5af81aa6347de31a7.

Ironically fixing the stub breaks too much stuff for now.

lib/librumprun_base/libc_stubs.c

index 59a4cb7c31aeca895257b1c86fc9c40522de9a26..40bb69125150478ce079b28af72f9f009fa202e4 100644 (file)
 #include <errno.h>
 #include <stdio.h>
 
+/* XXX: incorrect return value, need to fix other things first */
 #define STUB_ERRNO(name)                               \
   int name(void); int name(void) {                     \
        static int done = 0;                            \
        errno = ENOTSUP;                                \
-       if (done) return -1; done = 1;                  \
+       if (done) return ENOTSUP; done = 1;             \
        fprintf(stderr, "STUB ``%s'' called\n", #name); \
-       return -1;}
+       return ENOTSUP;}
 
 #define STUB_RETURN(name)                              \
   int name(void); int name(void) {                     \