Merge pull request #1751 from ssahani/word-machine

machine: fix #1739
This commit is contained in:
Daniel Mack 2015-11-02 12:38:24 +01:00
commit 0fc85c8670
1 changed files with 6 additions and 3 deletions

View File

@ -323,11 +323,14 @@ int machine_load(Machine *m) {
int ifi;
r = extract_first_word(&p, &word, NULL, 0);
if (r < 0)
return log_error_errno(r, "Failed to parse NETIF: %s", netif);
if (r == 0)
break;
else if (r == -ENOMEM)
return log_oom();
else if (r < 0) {
log_warning_errno(r, "Failed to parse NETIF: %s", netif);
continue;
}
if (safe_atoi(word, &ifi) < 0)
continue;