diff options
author | Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net> | 2012-06-16 00:11:16 +0000 |
---|---|---|
committer | Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net> | 2012-06-16 00:11:16 +0000 |
commit | 5b74ad19c37b7f03a8ad46cf10fc3fcd6067143a (patch) | |
tree | f9a0004150190d234c13927e173878f302251412 | |
parent | 49d72a06ce7c50164a532073cdb7207c1d6bf0c0 (diff) | |
download | flashrom-5b74ad19c37b7f03a8ad46cf10fc3fcd6067143a.zip flashrom-5b74ad19c37b7f03a8ad46cf10fc3fcd6067143a.tar.gz |
Remove exit() call from show_id
The only caller is able to check the return code and handle it
correctly.
Binary file (standard input) matches
Corresponding to flashrom svn r1545.
-rw-r--r-- | flashrom.c | 5 | ||||
-rw-r--r-- | layout.c | 2 |
2 files changed, 5 insertions, 2 deletions
@@ -1787,7 +1787,10 @@ int doit(struct flashctx *flash, int force, const char *filename, int read_it, #if CONFIG_INTERNAL == 1 if (programmer == PROGRAMMER_INTERNAL) - show_id(newcontents, size, force); + if (show_id(newcontents, size, force)) { + ret = 1; + goto out; + } #endif } @@ -137,7 +137,7 @@ int show_id(uint8_t *bios, int size, int force) "\n\n", mainboard_vendor, mainboard_part, lb_vendor, lb_part); - exit(1); + return 1; } } |