mirror of
https://sourceware.org/git/glibc.git
synced 2025-08-07 06:43:00 +03:00
tests: replace write by xwrite
Using write without cheks leads to warn unused result when __wur is enabled. Reviewed-by: Siddhesh Poyarekar <siddhesh@sourceware.org>
This commit is contained in:
committed by
Siddhesh Poyarekar
parent
a8c8889978
commit
026a84a54d
@@ -2,6 +2,8 @@
|
||||
|
||||
#include <stdio.h>
|
||||
|
||||
#include <support/xunistd.h>
|
||||
|
||||
static void do_prepare (void);
|
||||
#define PREPARE(argc, argv) do_prepare ()
|
||||
static int do_test (void);
|
||||
@@ -20,7 +22,7 @@ do_prepare (void)
|
||||
printf ("cannot create temporary file: %m\n");
|
||||
exit (1);
|
||||
}
|
||||
write (fd, pattern, sizeof (pattern));
|
||||
xwrite (fd, pattern, sizeof (pattern));
|
||||
close (fd);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user