Your message dated Thu, 13 Nov 2014 21:56:20 +0100 with message-id <[email protected]> and subject line Re: Bug#769457: dpkg memory leak has caused the Debian Bug report #769457, regarding dpkg memory leak to be marked as done.
This means that you claim that the problem has been dealt with. If this is not the case it is now your responsibility to reopen the Bug report if necessary, and/or fix the problem forthwith. (NB: If you are a system administrator and have no idea what this message is talking about, this may indicate a serious mail system misconfiguration somewhere. Please contact [email protected] immediately.) -- 769457: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=769457 Debian Bug Tracking System Contact [email protected] with problems
--- Begin Message ---Package: dpkg Version: 1.16.1.2 Tags: bug in dbdir.c: > /** * Get a pathname to the current on-disk database directory. * * > This function returns an allocated string, which should be freed with > * free(2). * * @param pathpart The pathpart to append to the new > pathnme. * * @return The newly allocated pathname. */ char * > dpkg_db_get_path(const char *pathpart) { char *pathname; > m_asprintf(&pathname, "%s/%s", db_dir, pathpart); return pathname; } That function is called in filesdb.c: > static void pkgadmindir_init(void) { infodir = > dpkg_db_get_path(INFODIR); } ...which is called in filesdb.c(again): > void filesdbinit(void) { struct filenamenode *fnn; int i; > pkgadmindir_init(); for (i=0; i<BINS; i++) for (fnn= bins[i]; fnn; > fnn= fnn->next) { fnn->flags= 0; fnn->oldhash = NULL; fnn->filestat = > NULL; } } Anyways, point is, pathname is never freed. Thanks, -- -- Joshua Rogers <https://internot.info/>
signature.asc
Description: OpenPGP digital signature
--- End Message ---
--- Begin Message ---Version: 1.16.3 On Fri, 2014-11-14 at 06:14:37 +1100, Joshua Rogers wrote: > Package: dpkg > Version: 1.16.1.2 > Tags: bug I think you mean to use the “Severity: normal” instead of “Tags: bug” as that tag does not exist. :) But normal is the default anyway. See also <https://www.debian.org/Bugs/Developer>. > in dbdir.c: > > /** * Get a pathname to the current on-disk database directory. * * > > This function returns an allocated string, which should be freed with > > * free(2). * * @param pathpart The pathpart to append to the new > > pathnme. * * @return The newly allocated pathname. */ char * > > dpkg_db_get_path(const char *pathpart) { char *pathname; > > m_asprintf(&pathname, "%s/%s", db_dir, pathpart); return pathname; } > > That function is called in filesdb.c: > > > static void pkgadmindir_init(void) { infodir = > > dpkg_db_get_path(INFODIR); } > > ...which is called in filesdb.c(again): > > void filesdbinit(void) { struct filenamenode *fnn; int i; > > pkgadmindir_init(); for (i=0; i<BINS; i++) for (fnn= bins[i]; fnn; > > fnn= fnn->next) { fnn->flags= 0; fnn->oldhash = NULL; fnn->filestat = > > NULL; } } > > Anyways, point is, pathname is never freed. This was fixed in commit d803a15517c39e6d95480f92807d7f6eda47d705, dpkg 1.16.3. I appreciate very much code review, but I'd like to request that you'd do it at least on the latest releases of the supported branches for 1.17.x and 1.16.x, prefereably first on the 1.17.x one. If the problem still persists on 1.16.x and is already fixed on 1.17.x I'd be fine with cherry-picking it there, if it's for resource leaks or similar. I have a bunch of those pending for 1.16.x, which I need to run through the security team or release team depending on ongoing discussions, though. Closing the report with this reply. Thanks, Guillem
--- End Message ---

