[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#558191: marked as done (Several errors in pcopy (1.5-2))

Your message dated Sun, 12 Sep 2010 16:01:54 +0000
with message-id <E1Oup06-0004Pc-06@merkel.debian.org>
and subject line Package pcopy has been removed from Debian
has caused the Debian Bug report #558191,
regarding Several errors in pcopy  (1.5-2)
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 owner@bugs.debian.org

558191: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=558191
Debian Bug Tracking System
Contact owner@bugs.debian.org with problems
--- Begin Message ---
Package: pcopy
Version: 1.5-2


After having a lot of problems with pcopy I found several bugs in the source code:

- Missing #include <string.h>, which brakes strerror(errno) and memset(); therefore you don't get an error message opening non-existent files in line 460 (see below), but instead a segfault (see http://www.mail-archive.com/ubuntu-bugs@lists.ubuntu.com/msg1635237.html).

- write_fd = open(dstdev, O_WRONLY+O_SYNC) in line 457 does't create new files, so I suggest to use something like

    if (fstat(read_fd, &read_sb) == -1)
        fprintf(stderr, ...);

    write_fd = creat(dstdev, read_sb.st_mode);
    if (write_fd < 0)
        fprintf(stderr, ...);


- The most severe bug (and I guess this leads to #484067) is the
    if (write_pos =! pos)   [should be of course "!="]
in line 176 when writing the new file.

I fixed these bugs (new source in attachment) and besides that I reformatted the source code and added some curly brackets in nested if-statements (so the diff is quite large and not very useful).


Preisknaller: WEB.DE DSL Flatrate für nur 16,99 Euro/mtl.! 

Attachment: pcopy_original.c
Description: Binary data

Attachment: pcopy_fixed.c
Description: Binary data

Attachment: pcopy.diff
Description: Binary data

--- End Message ---
--- Begin Message ---
Version: 1.5-2+rm

You filed the bug http://bugs.debian.org/558191 in Debian BTS
against the package pcopy. I'm closing it at *unstable*, but it will
remain open for older distributions.

For more information about this package's removal, read
http://bugs.debian.org/596552. That bug might give the reasons why
this package was removed and suggestions of possible replacements.

Don't hesitate to reply to this mail if you have any question.

Thank you for your contribution to Debian.

Luca Falavigna

--- End Message ---

Reply to: