Просмотр исходного кода

dpkg-deb: Use badusage() instead of ohshit() for usage errors

Guillem Jover лет назад: 13
Родитель
Сommit
ae0e9e0592
1 измененных файлов с 4 добавлено и 2 удалено
  1. 4 2
      dpkg-deb/extract.c

+ 4 - 2
dpkg-deb/extract.c

@@ -380,8 +380,10 @@ controlextractvextract(int admin, enum dpkg_tar_options taroptions,
   if (!dir) {
     if (admin)
       dir = EXTRACTCONTROLDIR;
-    else ohshit(_("--%s needs a target directory.\n"
-                "Perhaps you should be using dpkg --install ?"),cipaction->olong);
+    else
+      badusage(_("--%s needs a target directory.\n"
+                 "Perhaps you should be using dpkg --install ?"),
+               cipaction->olong);
   } else if (*argv) {
     badusage(_("--%s takes at most two arguments (.deb and directory)"),cipaction->olong);
   }