Re: [PATCH] conftest: fix transposed size and count arguments to fwrite.

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

 



On Mon, Nov 12, 2007 at 10:57:50PM +0100, Jim Meyering wrote:
> I noticed conftest fail and tracked it down to this:
> 
> 	conftest: fix transposed size and count arguments to fwrite.
> 	* tests/conftest.c: Include <string.h> and <errno.h>.
> 	  Also include strerror in diagnostic.
[...]
> -    if (fwrite(buffer, len, 1, stdout) != len) {
> -        fprintf(stderr, "Write failed\n");
> +    if (fwrite(buffer, 1, len, stdout) != len) {
> +	fprintf(stderr, "Write failed: %s\n", strerror (errno));

  Good catch, +1 !

Daniel

-- 
Red Hat Virtualization group http://redhat.com/virtualization/
Daniel Veillard      | virtualization library  http://libvirt.org/
veillard@xxxxxxxxxx  | libxml GNOME XML XSLT toolkit  http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine  http://rpmfind.net/

--
Libvir-list mailing list
Libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]