Hi guys,, 2011/8/17 Jonas Smedegaard <d...@jones.dk>: > On 11-08-16 at 01:34am, Stefano Rivera wrote: >> Apparently at some point I uploaded a netatalk backport to a Launchpad >> PPA, and people have been asking me to update it. I found the >> additional following issue when building it on oneiric: >> >> --- a/libatalk/util/server_ipc.c >> +++ b/libatalk/util/server_ipc.c >> @@ -129,7 +129,7 @@ >> EC_ZERO_LOG( setnonblock(fd, 1) ); >> unlink(name); >> address.sun_family = AF_UNIX; >> - address_length = sizeof(address.sun_family) + sprintf(address.sun_path, >> name); >> + address_length = sizeof(address.sun_family) + sprintf(address.sun_path, >> "%s", name); >> EC_ZERO_LOG( bind(fd, (struct sockaddr *)&address, address_length) ); >> EC_ZERO_LOG( listen(fd, 1024) ); >> >> @@ -161,7 +161,7 @@ >> EC_NEG1_LOG( fd = socket(PF_UNIX, SOCK_STREAM, 0) ); >> EC_ZERO_LOG( setnonblock(fd, 1) ); >> address.sun_family = AF_UNIX; >> - address_length = sizeof(address.sun_family) + sprintf(address.sun_path, >> name); >> + address_length = sizeof(address.sun_family) + sprintf(address.sun_path, >> "%s", name); >> >> EC_ZERO_LOG( connect(fd, (struct sockaddr *)&address, address_length) >> ); /* 1 */ >> LOG(log_debug, logtype_afpd, "ipc_client_uds: connected to master"); > > Thanks, Stefano! > > Frank, did you see above and agree with it? I would prefer > cherry-picking from upstream if at all possible.
While the sprintf may look strange it's ok as long as name doesn't contain format conversion specifiers. As the function is only ever called internally with name made from a #define, imo there's no need to custom patch this downstream. Anyway, I've committed the change for inclusion in 2.2.1. Thanks! -f -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org