msk: handle failures in 'fetch' when retrieving packages

This commit is contained in:
K Lange 2021-06-17 22:14:25 +09:00
parent 0f5e5158a9
commit 4b54f497d9

View File

@ -301,7 +301,10 @@ static int install_package(char * pkg) {
char cmd[1024];
sprintf(cmd, "fetch -o /tmp/msk.file -v %s/%s", msk_remote,
source);
system(cmd);
int status;
if ((status = system(cmd))) {
return status;
}
hashmap_set(hashmap_get(msk_manifest->sections, pkg), "source", "/tmp/msk.file");
}
}