print error on failed syscall in _ce_patch_create()

This commit is contained in:
Joe Bryan 2018-06-18 13:50:26 -04:00
parent 7633b5cc9c
commit 78a0d7732f

View File

@ -276,11 +276,13 @@ _ce_patch_create(u3_ce_patch* pat_u)
snprintf(ful_c, 8192, "%s/.urb/chk/control.bin", u3P.dir_c);
if ( -1 == (pat_u->ctl_i = open(ful_c, O_RDWR | O_CREAT | O_EXCL, 0666)) ) {
perror(ful_c);
c3_assert(0);
}
snprintf(ful_c, 8192, "%s/.urb/chk/memory.bin", u3P.dir_c);
if ( -1 == (pat_u->mem_i = open(ful_c, O_RDWR | O_CREAT | O_EXCL, 0666)) ) {
perror(ful_c);
c3_assert(0);
}
}