mirror of
https://github.com/ipmitool/ipmitool.git
synced 2025-05-10 18:47:22 +00:00
3600942 check return code
This commit is contained in:
parent
6eda3b5482
commit
15d683d86d
@ -736,7 +736,10 @@ ipmi_sunoem_sshkey_set(struct ipmi_intf * intf, uint8_t uid, char * ifile)
|
||||
i_size = SSHKEY_BLOCK_SIZE;
|
||||
|
||||
memset(wbuf, 0, SSHKEY_BLOCK_SIZE);
|
||||
fseek(fp, r, SEEK_SET);
|
||||
if (-1 == fseek(fp, r, SEEK_SET)) {
|
||||
lprintf(LOG_ERR, "Seek error %s. %s", ifile, strerror(errno));
|
||||
return -1;
|
||||
}
|
||||
count = fread(wbuf+3, 1, i_size, fp);
|
||||
if (count != i_size) {
|
||||
lprintf(LOG_ERR, "Unable to read %d bytes from file %s", i_size, ifile);
|
||||
|
Loading…
x
Reference in New Issue
Block a user