diff -Nru ptop-3.6.2/debian/changelog ptop-3.6.2/debian/changelog --- ptop-3.6.2/debian/changelog 2010-12-23 20:09:04.000000000 +0000 +++ ptop-3.6.2/debian/changelog 2012-02-06 20:43:50.000000000 +0000 @@ -1,3 +1,13 @@ +ptop (3.6.2-5) unstable; urgency=low + + * Applyed patch (closes: #594077) + * Adopted packages Bug-Debian: (closes: #654552) + * fixed lintian warnings + * Changed Standards-Version to 3.9.2 + * Closes request for sponsorshop Bug-Debian: (closes: #658775) + + -- Bastiaan Franciscus van den Dikkenberg Sat, 04 Feb 2012 12:00:00 +0100 + ptop (3.6.2-4) unstable; urgency=low * Merge with Ubuntu diff -Nru ptop-3.6.2/debian/control ptop-3.6.2/debian/control --- ptop-3.6.2/debian/control 2010-12-23 20:09:04.000000000 +0000 +++ ptop-3.6.2/debian/control 2012-02-04 11:13:40.000000000 +0000 @@ -1,9 +1,9 @@ Source: ptop Section: misc Priority: optional -Maintainer: Francois Marier +Maintainer: Bastiaan Franciscus van den Dikkenberg Build-Depends: debhelper (>= 8), autotools-dev, libpq-dev, libncurses5-dev -Standards-Version: 3.9.1 +Standards-Version: 3.9.2 Homepage: http://ptop.projects.postgresql.org/ Vcs-Git: git://git.debian.org/git/collab-maint/ptop.git Vcs-Browser: http://git.debian.org/?p=collab-maint/ptop.git;a=summary diff -Nru ptop-3.6.2/debian/patches/pg_top.segfault.patch ptop-3.6.2/debian/patches/pg_top.segfault.patch --- ptop-3.6.2/debian/patches/pg_top.segfault.patch 1970-01-01 00:00:00.000000000 +0000 +++ ptop-3.6.2/debian/patches/pg_top.segfault.patch 2012-02-06 20:43:13.000000000 +0000 @@ -0,0 +1,63 @@ +Description: pg_top batch-mode segfaults +Origin: http://pgfoundry.org/tracker/index.php?func=detail&aid=1011146&group_id=1000300&atid=1129 +Bug-Debian: http://bugs.debian.org/594077 +Author: Bastiaan Franciscus van den Dikkenberg + +Last-Update: 2012-02-03 + +diff -u pg_top.orig/display.c pg_top/display.c +--- pg_top.orig/display.c 2012-01-14 16:26:23.000000000 -0800 ++++ pg_top/display.c 2012-01-13 23:42:19.000000000 -0800 +@@ -313,8 +313,11 @@ + } + + /* write */ +- fputs(new, stdout); +- curr_x += strlen(new); ++ if (new != NULL) ++ { ++ fputs(new, stdout); ++ curr_x += strlen(new); ++ } + + return; + } +diff -u pg_top.orig/screen.c pg_top/screen.c +--- pg_top.orig/screen.c 2012-01-14 16:26:23.000000000 -0800 ++++ pg_top/screen.c 2012-01-13 23:36:49.000000000 -0800 +@@ -141,7 +141,19 @@ + #endif /* TIOCGSIZE */ + #endif /* TIOCGWINSZ */ + +- (void) strcpy(lower_left, tgoto(cursor_motion, 0, screen_length - 1)); ++ char *lower_left_motion = ""; ++ // get_screensize() can be called from main() without cursor_motion ++ // having been set, so we protect against that possibility. ++ if (smart_terminal == Yes) ++ { ++ // We need to account for the fact that tgoto() might return NULL. ++ lower_left_motion = tgoto(cursor_motion, 0, screen_length - 1); ++ if (lower_left_motion == NULL) ++ { ++ lower_left_motion = ""; ++ } ++ } ++ (void) strcpy(lower_left, lower_left_motion); + } + + void +@@ -252,7 +264,13 @@ + PC = (PCptr = tgetstr("pc", &bufptr)) ? *PCptr : 0; + + /* set convenience strings */ +- (void) strcpy(home, tgoto(cursor_motion, 0, 0)); ++ // We need to account for the fact that tgoto() might return NULL. ++ char *home_motion = tgoto(cursor_motion, 0, 0); ++ if (home_motion == NULL) ++ { ++ home_motion = ""; ++ } ++ (void) strcpy(home, home_motion); + /* (lower_left is set in get_screensize) */ + + /* get the actual screen size with an ioctl, if needed */ diff -Nru ptop-3.6.2/debian/patches/series ptop-3.6.2/debian/patches/series --- ptop-3.6.2/debian/patches/series 2010-12-23 20:09:04.000000000 +0000 +++ ptop-3.6.2/debian/patches/series 2012-02-04 11:17:06.000000000 +0000 @@ -1,2 +1,3 @@ manpage_hyphen.patch ld-as-needed.diff +pg_top.segfault.patch diff -Nru ptop-3.6.2/debian/rules ptop-3.6.2/debian/rules --- ptop-3.6.2/debian/rules 2010-12-23 20:09:04.000000000 +0000 +++ ptop-3.6.2/debian/rules 2012-02-04 11:12:17.000000000 +0000 @@ -20,7 +20,10 @@ ./configure --host=$(DEB_HOST_GNU_TYPE) --build=$(DEB_BUILD_GNU_TYPE) --prefix=/usr --mandir=\$${prefix}/share/man --infodir=\$${prefix}/share/info CFLAGS="$(CFLAGS)" LDFLAGS="-Wl,-z,defs" -build: build-stamp +build: build-stamp build-arch build-indep +build-arch: build-stamp +build-indep: build-stamp + build-stamp: config.status dh_testdir diff -Nru ptop-3.6.2/debian/watch ptop-3.6.2/debian/watch --- ptop-3.6.2/debian/watch 2010-12-23 20:09:04.000000000 +0000 +++ ptop-3.6.2/debian/watch 2012-02-04 11:15:02.000000000 +0000 @@ -1,11 +1,3 @@ -# Example watch control file for uscan -# Rename this file to "watch" and then you can run the "uscan" command -# to check for upstream updates and more. -# See uscan(1) for format - -# Compulsory line, this is a version 3 file version=3 - -# Rubyforge - will work when upstream moves from weird version numbers opts="uversionmangle=s/-beta/~beta/" \ http://pgfoundry.org/frs/?group_id=1000300 .*\/pg_top-(.*)\.tar\.gz