Browse Source

[prefix] Eliminate uninitialised variable

Signed-off-by: Michael Brown <mcb30@ipxe.org>
tags/v1.20.1
Michael Brown 12 years ago
parent
commit
b4bb39909e
1 changed files with 2 additions and 0 deletions
  1. 2
    0
      src/arch/i386/core/runtime.c

+ 2
- 0
src/arch/i386/core/runtime.c View File

@@ -193,6 +193,7 @@ static int initrd_init ( void ) {
193 193
 	if ( ! image ) {
194 194
 		DBGC ( colour, "RUNTIME could not allocate image for "
195 195
 		       "initrd\n" );
196
+		rc = -ENOMEM;
196 197
 		goto err_alloc_image;
197 198
 	}
198 199
 	image_set_name ( image, "<INITRD>" );
@@ -202,6 +203,7 @@ static int initrd_init ( void ) {
202 203
 	if ( ! image->data ) {
203 204
 		DBGC ( colour, "RUNTIME could not allocate %zd bytes for "
204 205
 		       "initrd\n", initrd_len );
206
+		rc = -ENOMEM;
205 207
 		goto err_umalloc;
206 208
 	}
207 209
 	image->len = initrd_len;

Loading…
Cancel
Save