Changeset 12811
- Timestamp:
- Sep 11, 2009, 3:51:22 AM (15 years ago)
- File:
-
- 1 edited
-
trunk/source/lisp-kernel/image.c (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/source/lisp-kernel/image.c
r11623 r12811 26 26 #endif 27 27 #include <stdio.h> 28 #include <limits.h> 28 29 29 30 … … 175 176 off_t 176 177 pos = seek_to_next_page(fd), advance; 177 int178 natural 178 179 mem_size = sect->memory_size; 179 180 void *addr; … … 379 380 writebuf(int fd, char *bytes, natural n) 380 381 { 381 natural remain = n ;382 intresult;382 natural remain = n, this_size; 383 signed_natural result; 383 384 384 385 while (remain) { 385 result = write(fd, bytes, remain); 386 this_size = remain; 387 if (this_size > INT_MAX) { 388 this_size = INT_MAX; 389 } 390 result = write(fd, bytes, this_size); 386 391 if (result < 0) { 387 392 return errno; 388 393 } 389 394 bytes += result; 395 390 396 remain -= result; 391 397 }
Note:
See TracChangeset
for help on using the changeset viewer.
