This is primarily to silence a gcc warning, but it's better to reflect
the error from system() up to the caller. In this case we don't
actually use it for anything, but that's OK.
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
#ifdef HAS_STDLIB_H
#include <stdlib.h>
#endif
+#ifdef HAVE_ERRNO_H
+#include <errno.h>
+#else
+extern int errno;
+#endif
#include "ss_internal.h"
#include <stdio.h>
return SS_ET_ESCAPE_DISABLED;
else {
line_ptr++;
- system(line_ptr);
- return 0;
+ return (system(line_ptr) < 0) ? errno : 0;
}
}