Преглед изворни кода

dpkg-deb: Change temporary directory suffix to dpkg-deb

Makes it more obvious who created the directory.
Guillem Jover пре 16 година
родитељ
комит
c7ade13aa8
2 измењених фајлова са 3 додато и 3 уклоњено
  1. 2 2
      dpkg-deb/build.c
  2. 1 1
      dpkg-deb/info.c

+ 2 - 2
dpkg-deb/build.c

@@ -414,7 +414,7 @@ void do_build(const char *const *argv) {
   /* Create a temporary file to store the control data in. Immediately unlink
    * our temporary file so others can't mess with it.
    */
-  tfbuf = path_make_temp_template("dpkg");
+  tfbuf = path_make_temp_template("dpkg-deb");
   if ((gzfd= mkstemp(tfbuf)) == -1) ohshite(_("failed to make tmpfile (control)"));
   /* make sure it's gone, the fd will remain until we close it */
   if (unlink(tfbuf)) ohshit(_("failed to unlink tmpfile (control), %s"),
@@ -463,7 +463,7 @@ void do_build(const char *const *argv) {
    * can't mess with it. */
   if (!oldformatflag) {
     close(gzfd);
-    tfbuf = path_make_temp_template("dpkg");
+    tfbuf = path_make_temp_template("dpkg-deb");
     if ((gzfd= mkstemp(tfbuf)) == -1) ohshite(_("failed to make tmpfile (data)"));
     /* make sure it's gone, the fd will remain until we close it */
     if (unlink(tfbuf)) ohshit(_("failed to unlink tmpfile (data), %s"),

+ 1 - 1
dpkg-deb/info.c

@@ -74,7 +74,7 @@ static void info_prepare(const char *const **argvp,
   *debarp= *(*argvp)++;
   if (!*debarp) badusage(_("--%s needs a .deb filename argument"),cipaction->olong);
 
-  dbuf = mkdtemp(path_make_temp_template("dpkg"));
+  dbuf = mkdtemp(path_make_temp_template("dpkg-deb"));
   if (!dbuf)
     ohshite(_("failed to create temporary directory"));
   *directoryp= dbuf;