public
/
ack.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9ca8f42
)
* Was trying to use the new system API which is not ready causing stack issues.
author
carl
<cecodere@yahoo.ca>
Tue, 19 Feb 2019 16:44:32 +0000
(
00:44
+0800)
committer
carl
<cecodere@yahoo.ca>
Tue, 19 Feb 2019 16:44:32 +0000
(
00:44
+0800)
modules/src/input/inp_pkg.body
patch
|
blob
|
history
diff --git
a/modules/src/input/inp_pkg.body
b/modules/src/input/inp_pkg.body
index
9950f34
..
2a025cd
100644
(file)
--- a/
modules/src/input/inp_pkg.body
+++ b/
modules/src/input/inp_pkg.body
@@
-107,7
+107,7
@@
INP_rdfile(fd, fn, size, pbuf)
register long *size;
char **pbuf; /* output parameter */
{
-
long
rsize;
+
int
rsize;
if (
((*size = sys_filesize(fn))) < 0
@@
-217,13
+217,12
@@
INP_rdblock(fd, buf, n)
char *buf;
int *n;
{
- long readSize;
- readSize = (size_t)*n;
- if (!sys_read(fd, buf, INP_BUFSIZE, &readSize)) {
+
+ if (!sys_read(fd, buf, INP_BUFSIZE, n)) {
return 0;
}
- *n = (int)readSize;
+
buf[*n] = '\0';
return 1;
}