Commit a5337149 authored by Jiaxing Wang's avatar Jiaxing Wang Committed by Alexandre Julliard

regedit: Avoid appending '\0' to string value of imported key.

parent 2100d3e1
...@@ -376,7 +376,6 @@ static LONG setValue(WCHAR* val_name, WCHAR* val_data, BOOL is_unicode) ...@@ -376,7 +376,6 @@ static LONG setValue(WCHAR* val_name, WCHAR* val_data, BOOL is_unicode)
return ERROR_INVALID_DATA; return ERROR_INVALID_DATA;
val_data[dwLen-1] = '\0'; /* remove last quotes */ val_data[dwLen-1] = '\0'; /* remove last quotes */
lpbData = (BYTE*) val_data; lpbData = (BYTE*) val_data;
dwLen++; /* include terminating null */
dwLen = dwLen * sizeof(WCHAR); /* size is in bytes */ dwLen = dwLen * sizeof(WCHAR); /* size is in bytes */
} }
else if (dwParseType == REG_DWORD) /* Convert the dword types */ else if (dwParseType == REG_DWORD) /* Convert the dword types */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment