Przeglądaj źródła

dpkg: Do not print pointers in debug output messages

This does not give any meaningful information, besides the pointers
being equal or different. Print an actual file or package name instead.
Guillem Jover 12 lat temu
rodzic
commit
183fcc5b4c
3 zmienionych plików z 5 dodań i 3 usunięć
  1. 2 0
      debian/changelog
  2. 2 2
      src/help.c
  3. 1 1
      src/trigproc.c

+ 2 - 0
debian/changelog

@@ -104,6 +104,8 @@ dpkg (1.17.14) UNRELEASED; urgency=low
   * Test suite:
     - Do not leave temporary files behind on failure or when interrupted.
   * Add --build and --extract command aliases to dpkg-source.
+  * Print file or package names instead of pointers in dpkg debug output,
+    to make it more meaningful and reproducible.
 
   [ Raphaël Hertzog ]
   * Explain better in deb-triggers(5) why interest/activate-noawait should be

+ 2 - 2
src/help.c

@@ -327,8 +327,8 @@ void oldconffsetflags(const struct conffile *searchconff) {
     namenode->flags |= fnnf_old_conff;
     if (!namenode->oldhash)
       namenode->oldhash= searchconff->hash;
-    debug(dbg_conffdetail, "oldconffsetflags '%s' namenode %p flags %o",
-          searchconff->name, namenode, namenode->flags);
+    debug(dbg_conffdetail, "oldconffsetflags '%s' namenode '%s' flags %o",
+          searchconff->name, namenode->name, namenode->flags);
     searchconff= searchconff->next;
   }
 }

+ 1 - 1
src/trigproc.c

@@ -294,7 +294,7 @@ check_trigger_cycle(struct pkginfo *processing_now)
 
 	/* We give up on the _earliest_ package involved. */
 	giveup = tortoise->pkgs->pkg;
-	debug(dbg_triggers, "check_triggers_cycle pnow=%s giveup=%p",
+	debug(dbg_triggers, "check_triggers_cycle pnow=%s giveup=%s",
 	      pkg_name(processing_now, pnaw_always),
 	      pkg_name(giveup, pnaw_always));
 	assert(giveup->status == PKG_STAT_TRIGGERSAWAITED ||