diff options
| author | Michael Brown | 2011-03-09 18:21:10 +0100 |
|---|---|---|
| committer | Michael Brown | 2011-03-09 18:21:34 +0100 |
| commit | 4562223420c983864b2335b0a9bfe8d70993e123 (patch) | |
| tree | e2db33999351fdc3bee2a8d4cd6ee3f64d990611 /src | |
| parent | [image] Simplify use of imgdownload() (diff) | |
| download | ipxe-4562223420c983864b2335b0a9bfe8d70993e123.tar.gz ipxe-4562223420c983864b2335b0a9bfe8d70993e123.tar.xz ipxe-4562223420c983864b2335b0a9bfe8d70993e123.zip | |
[image] Avoid ending up with multiple selected images on re-registration
Signed-off-by: Michael Brown <mcb30@ipxe.org>
Diffstat (limited to 'src')
| -rw-r--r-- | src/core/image.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/core/image.c b/src/core/image.c index 01091f1b5..86c264c26 100644 --- a/src/core/image.c +++ b/src/core/image.c @@ -128,6 +128,12 @@ int register_image ( struct image *image ) { imgindex++ ); } + /* Avoid ending up with multiple "selected" images on + * re-registration + */ + if ( image_find_selected() ) + image->flags &= ~IMAGE_SELECTED; + /* Add to image list */ image_get ( image ); image->flags |= IMAGE_REGISTERED; |
