diff -u nbd-3.16.2/debian/changelog nbd-3.16.2/debian/changelog --- nbd-3.16.2/debian/changelog +++ nbd-3.16.2/debian/changelog @@ -1,3 +1,12 @@ +nbd (1:3.16.2-1ubuntu1) bionic; urgency=medium + + * Fix bugs causing nbd-smoke-test to fail (LP: #1772024) + - Fix segfault when exporting only from a file on the command line. + - Fix fd leaks when fork fails. + - debian/control: change Maintainer + + -- Thadeu Lima de Souza Cascardo Wed, 30 May 2018 15:10:02 -0300 + nbd (1:3.16.2-1) unstable; urgency=medium * New upstream release diff -u nbd-3.16.2/debian/control nbd-3.16.2/debian/control --- nbd-3.16.2/debian/control +++ nbd-3.16.2/debian/control @@ -1,7 +1,8 @@ Source: nbd Section: admin Priority: optional -Maintainer: Wouter Verhelst +Maintainer: Ubuntu Developers +XSBC-Original-Maintainer: Wouter Verhelst Build-Depends: debhelper (>= 9), libglib2.0-dev (>= 2.26.0), libgnutls28-dev Standards-Version: 3.9.4 Vcs-Git: git://anonscm.debian.org/users/wouter/nbd.git only in patch2: unchanged: --- nbd-3.16.2.orig/nbd-server.c +++ nbd-3.16.2/nbd-server.c @@ -2768,6 +2768,8 @@ pid = fork(); if (pid < 0) { msg(LOG_ERR, "Could not fork (%s)", strerror(errno)); + close(sockets[0]); + close(sockets[1]); goto out; } if (pid > 0) { /* Parent */ @@ -2911,7 +2913,8 @@ break; } } - buf = g_malloc0(len); + buf = g_malloc0(len + 1); + buf[len] = 0; readit(socket, buf, len); for(i=0; ilen; i++) { SERVER* srv = &g_array_index(servers, SERVER, i);