chiark / gitweb /
prefork: add a magic number to prefork-interp
[chiark-utils.git] / cprogs / prefork.c
index 25639418fa9685fceb4cd6972b8318dd0185084f..909d0658ebf7f407f317f32164299b8306ff7101 100644 (file)
@@ -19,7 +19,7 @@ void vmsgcore(int estatus, int errnoval, const char *fmt, va_list al) {
   if (logging) {
     const char *fmt_use = fmt;
     char *fmt_free = 0;
-    if (errnoval) {
+    if (errnoval!=-1) {
       r = asprintf(&fmt_free, "%s: %%m", fmt);
       if (r) {
        fmt_free = 0;
@@ -206,6 +206,7 @@ void process_opts(const char *const **argv_io) {
   const char *smashedopt;
 
   sha256_init(&identsc);
+  ident_addinit();
 
   if ((*argv_io)[0] &&
       (smashedopt = (*argv_io)[1]) &&