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

Support conffiles with spaces when diffing them

Closes: #147583
Guillem Jover лет назад: 15
Родитель
Сommit
980da6d9b5
2 измененных файлов с 3 добавлено и 1 удалено
  1. 1 0
      debian/changelog
  2. 2 1
      src/configure.c

+ 1 - 0
debian/changelog

@@ -29,6 +29,7 @@ dpkg (1.16.1) UNRELEASED; urgency=low
   * Generate filenames following current conventions on “dpkg-split --join”,
   * Generate filenames following current conventions on “dpkg-split --join”,
     by including the architecture in the debian-split member of a split
     by including the architecture in the debian-split member of a split
     package and using underscores to separate filename parts.
     package and using underscores to separate filename parts.
+  * Support conffiles with spaces when diffing them. Closes: #147583
 
 
   [ Updated man page translations ]
   [ Updated man page translations ]
   * German (Helge Kreutzmann).
   * German (Helge Kreutzmann).

+ 2 - 1
src/configure.c

@@ -42,6 +42,7 @@
 #include <dpkg/i18n.h>
 #include <dpkg/i18n.h>
 #include <dpkg/dpkg.h>
 #include <dpkg/dpkg.h>
 #include <dpkg/dpkg-db.h>
 #include <dpkg/dpkg-db.h>
+#include <dpkg/string.h>
 #include <dpkg/buffer.h>
 #include <dpkg/buffer.h>
 #include <dpkg/file.h>
 #include <dpkg/file.h>
 #include <dpkg/subproc.h>
 #include <dpkg/subproc.h>
@@ -510,7 +511,7 @@ showdiff(const char *old, const char *new)
 			pager = DEFAULTPAGER;
 			pager = DEFAULTPAGER;
 
 
 		sprintf(cmdbuf, DIFF " -Nu %.250s %.250s | %.250s",
 		sprintf(cmdbuf, DIFF " -Nu %.250s %.250s | %.250s",
-		        old, new, pager);
+		        str_quote_meta(old), str_quote_meta(new), pager);
 
 
 		command_shell(cmdbuf, _("conffile difference visualizer"));
 		command_shell(cmdbuf, _("conffile difference visualizer"));
 	}
 	}