projects
/
platform
/
upstream
/
gummiboot.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
fc1e8f3
)
setup: if all BootXXXX are used, find the next slot behind, don't overwrite Boot0000
author
Kay Sievers
<kay@vrfy.org>
Sat, 16 Mar 2013 17:41:06 +0000
(18:41 +0100)
committer
Kay Sievers
<kay@vrfy.org>
Sat, 16 Mar 2013 17:41:06 +0000
(18:41 +0100)
https://bbs.archlinux.org/viewtopic.php?pid=1242470#p1242470
src/setup/setup.c
patch
|
blob
|
history
diff --git
a/src/setup/setup.c
b/src/setup/setup.c
index
962126c
..
c9249ee
100644
(file)
--- a/
src/setup/setup.c
+++ b/
src/setup/setup.c
@@
-900,6
+900,11
@@
static int find_slot(const uint8_t uuid[16], const char *path, uint16_t *id) {
goto finish;
}
+ /* use the next one */
+ if (i == 0xffff)
+ return -ENOSPC;
+ new_id = i;
+
finish:
*id = new_id;
free(options);