Initialize the parameters to NULL so that a later reload doesn't try to free
uninitialized memory. Fixes a crash on boot with a preloaded settings file present that wasn't used before the boot device was available (like the vm settings file). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28119 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -645,6 +645,7 @@ driver_settings_init(kernel_args *args)
|
|||||||
handle->text = NULL;
|
handle->text = NULL;
|
||||||
|
|
||||||
strlcpy(handle->name, settings->name, sizeof(handle->name));
|
strlcpy(handle->name, settings->name, sizeof(handle->name));
|
||||||
|
handle->settings.parameters = NULL;
|
||||||
handle->magic = 0;
|
handle->magic = 0;
|
||||||
// this triggers parsing the settings when they are actually used
|
// this triggers parsing the settings when they are actually used
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user