diff options
author | Russ Cox <rsc@swtch.com> | 2010-10-07 04:23:17 -0400 |
---|---|---|
committer | Russ Cox <rsc@swtch.com> | 2010-10-07 04:23:17 -0400 |
commit | bb72982b79e09bb055930c2877ac7077b341cf84 (patch) | |
tree | 4215aae911ed210ed5ac5e6135183dbfc7c9a28d /src/libmach | |
parent | c54202e5776f228276ec95e6befcceda92fe2042 (diff) | |
download | plan9port-bb72982b79e09bb055930c2877ac7077b341cf84.tar.gz plan9port-bb72982b79e09bb055930c2877ac7077b341cf84.tar.bz2 plan9port-bb72982b79e09bb055930c2877ac7077b341cf84.zip |
libmach: fix warning about preadn
R=rsc
http://codereview.appspot.com/2388041
Diffstat (limited to 'src/libmach')
-rw-r--r-- | src/libmach/macho.c | 21 |
1 files changed, 0 insertions, 21 deletions
diff --git a/src/libmach/macho.c b/src/libmach/macho.c index 7f12735a..38cb2374 100644 --- a/src/libmach/macho.c +++ b/src/libmach/macho.c @@ -6,27 +6,6 @@ /* http://www.channelu.com/NeXT/NeXTStep/3.3/nd/DevTools/14_MachO/MachO.htmld/ */ -static long -preadn(int fd, void *vdata, uint32 ulen, uint64 offset) -{ - long n; - uchar *data; - long len; - - len = ulen; - data = vdata; -/* fprint(2, "readn 0x%llux 0x%ux\n", offset, ulen); */ - while(len > 0){ - n = pread(fd, data, len, offset); - if(n <= 0) - break; - data += n; - offset += n; - len -= n; - } - return data-(uchar*)vdata; -} - Macho* machoopen(char *name) |