summaryrefslogtreecommitdiff
path: root/app-shells/bash/files/bash-5.3-read-sys.patch
blob: 9491d727ccedc6c2efb20ed20c68bae799206839 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
Extracted from https://cgit.git.savannah.gnu.org/cgit/bash.git/commit/?h=devel&id=01070d43248fb97f3b2a08d780ae5a392573ce34
(note https://lists.gnu.org/archive/html/bug-readline/2025-07/msg00001.html wrt Chet not discouraging
such cherry-picking)

https://lists.gnu.org/archive/html/bug-bash/2025-07/msg00031.html
https://github.com/desultory/ugrd/pull/328
--- builtins/evalfile.c
+++ builtins/evalfile.c
@@ -160,8 +160,10 @@ file_error_and_exit:
       nr = read (fd, string, file_size);
       if (nr >= 0)
 	string[nr] = '\0';
+#if 0
       if (nr != file_size)
 	nr = -1;		/* XXX - didn't get the whole file */
+#endif
     }
   else
     nr = zmapfd (fd, &string, 0);