dos33: dos33_raw: fix bug where it never exited

This commit is contained in:
Vince Weaver 2020-08-20 13:05:13 -04:00
parent feea160820
commit 87ad2caad2
1 changed files with 2 additions and 1 deletions

View File

@ -59,7 +59,8 @@ int main(int argc, char **argv) {
/* write until out of space */
while(1) {
result=read(file_fd,buffer,256);
if (result<0) break;
if (result<0) break; /* error */
if (result==0) break; /* done */
result=write(disk_image_fd,buffer,result);
if (result<0) {
fprintf(stderr,"Error writing image: %s\n",