david/ipxe
Archived
1
0

[image] Avoid ending up with multiple selected images on re-registration

Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
Michael Brown 2011-03-09 17:21:10 +00:00
parent 9fa4ac2e9a
commit 4562223420

View File

@ -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;