Package: amd64-libs
Version: 1.2

I was tempted to make this "Severity: critical", but since I doubt the
bug will manifest itself anytime soon, I'm leaving it as normal. I hope
this was the right thing to do.

While testing amd64-libs-dev with piuparts, I noticed
that /usr/lib64/libncurses.so.5 is left behind on the system and while
looking for the package that is responsible for this, I noticed that the
amd64-libs postrm script seems to have a potentially serious bug:

if grep -v '^/lib64$' /etc/ld.so.conf > /etc/ld.so.conf-amd64-libs-tmp;
then
  chmod 0644 /etc/ld.so.conf-amd64-libs-tmp
  mv /etc/ld.so.conf-amd64-libs-tmp /etc/ld.so.conf
else
  rm -f /etc/ld.so.conf
fi

I'm pretty sure that the else part should
remove /etc/ld.so.conf-amd64-libs-tmp instead of /etc/ld.so.conf.

The error is repeated in the other if statements, a total of three
times, if I count correctly. Later in the postrm the temporary file is
removed anyway, so I guess the elses could be removed completely?

The postrm script also runs ldconfig only after it has
modified /etc/ld.so.conf. Would it not be sensible to run it beforehand,
so that ldconfig will remove links in the various 64-bit library
directories? (I suspect this is why the libncurses.so.5 link is left
behind on purge, but I haven't investigated it yet.)



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to