Fix Bug in process.c initialising a char to NULL
This commit is contained in:
@@ -147,7 +147,7 @@ start_process (void *file_name_)
|
|||||||
|
|
||||||
/* Push a null pointer sentinel inside argv. */
|
/* Push a null pointer sentinel inside argv. */
|
||||||
if_.esp -= sizeof (char *);
|
if_.esp -= sizeof (char *);
|
||||||
*(char *) if_.esp = NULL;
|
*(char *) if_.esp = 0;
|
||||||
|
|
||||||
/* Push pointer to the process file name to the stack. */
|
/* Push pointer to the process file name to the stack. */
|
||||||
char **argv;
|
char **argv;
|
||||||
@@ -173,7 +173,7 @@ start_process (void *file_name_)
|
|||||||
|
|
||||||
/* Push fake return address (null pointer). */
|
/* Push fake return address (null pointer). */
|
||||||
if_.esp -= sizeof (char *);
|
if_.esp -= sizeof (char *);
|
||||||
*(char *) if_.esp = NULL;
|
*(char *) if_.esp = 0;
|
||||||
|
|
||||||
/* If load failed, quit. */
|
/* If load failed, quit. */
|
||||||
palloc_free_page (file_name_);
|
palloc_free_page (file_name_);
|
||||||
|
|||||||
Reference in New Issue
Block a user