mirror of
https://github.com/coreutils/coreutils.git
synced 2026-10-28 09:44:34 +08:00
wc: make sure input buffer for neon 'wc -l' is aligned
* src/wc_neon.c (wc_lines_neon): Use alignas.
This commit is contained in:
1 parent
9b855166ed
commit
9b29c9c899
1 file changed
+1
-1
+1
-1
@@ -35,7 +35,7 @@ wc_lines_neon (int fd)
|
||||
|
||||
while (true)
|
||||
{
|
||||
unsigned char neon_buf[IO_BUFSIZE];
|
||||
unsigned char alignas (16) neon_buf[IO_BUFSIZE];
|
||||
ssize_t bytes_read = read (fd, neon_buf, sizeof neon_buf);
|
||||
if (bytes_read <= 0)
|
||||
return (struct wc_lines) { bytes_read == 0 ? 0 : errno, lines, bytes };
|
||||
|
||||
Reference in new issue
Block a user