Explorar o código

Fix missing nul

Jeremy Soller %!s(int64=6) %!d(string=hai) anos
pai
achega
dd65d0c0c8
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      src/header/getopt/mod.rs

+ 1 - 1
src/header/getopt/mod.rs

@@ -88,7 +88,7 @@ pub unsafe extern "C" fn getopt_long(
                                         stdio::fputs(*argv as _, &mut *stdio::stderr);
                                         stdio::fputs(": option '--\0".as_ptr() as _, &mut *stdio::stderr);
                                         stdio::fputs(current_arg, &mut *stdio::stderr);
-                                        stdio::fputs("' requires an argument\n".as_ptr() as _, &mut *stdio::stderr);
+                                        stdio::fputs("' requires an argument\n\0".as_ptr() as _, &mut *stdio::stderr);
                                         return b'?' as c_int;
                                     }
                                 }