Added patch to avoid appending duplicate NULL character when importing keys with regedit.

This commit is contained in:
Sebastian Lackner 2015-01-13 05:46:52 +01:00
parent 0d07d50b91
commit ce0a7a882b
5 changed files with 76 additions and 16 deletions

View File

@ -37,8 +37,9 @@ Wine. All those differences are also documented on the
Included bug fixes and improvements
===================================
**Bugfixes and features included in the next upcoming release [1]:**
**Bugfixes and features included in the next upcoming release [2]:**
* Do not append duplicate NULL characters when importing keys with regedit ([Wine Bug #37575](https://bugs.winehq.org/show_bug.cgi?id=37575))
* Support for DDS file format in D3DXSaveTextureToFileInMemory ([Wine Bug #26898](https://bugs.winehq.org/show_bug.cgi?id=26898))

1
debian/changelog vendored
View File

@ -1,6 +1,7 @@
wine-staging (1.7.35) UNRELEASED; urgency=low
* Add support for Gentoo epatch backend to patchinstall.sh.
* Added patch to implement support for DDS file format in D3DXSaveTextureToFileInMemory.
* Added patch to avoid appending duplicate NULL character when importing keys with regedit.
-- Sebastian Lackner <sebastian@fds-team.de> Mon, 12 Jan 2015 13:06:22 +0100
wine-staging (1.7.34-1) unstable; urgency=low

View File

@ -132,6 +132,7 @@ patch_enable_all ()
enable_nvcuvid_CUDA_Video_Support="$1"
enable_ole32_CoWaitForMultipleHandles="$1"
enable_quartz_MediaSeeking_Positions="$1"
enable_regedit_String_Termination="$1"
enable_riched20_IText_Interface="$1"
enable_secur32_Schannel_ContextAttr="$1"
enable_server_ACL_Compat="$1"
@ -425,6 +426,9 @@ patch_enable ()
quartz-MediaSeeking_Positions)
enable_quartz_MediaSeeking_Positions="$2"
;;
regedit-String_Termination)
enable_regedit_String_Termination="$2"
;;
riched20-IText_Interface)
enable_riched20_IText_Interface="$2"
;;
@ -2229,6 +2233,21 @@ if test "$enable_quartz_MediaSeeking_Positions" -eq 1; then
) >> "$patchlist"
fi
# Patchset regedit-String_Termination
# |
# | This patchset fixes the following Wine bugs:
# | * [#37575] Do not append duplicate NULL characters when importing keys with regedit
# |
# | Modified files:
# | * programs/regedit/regproc.c
# |
if test "$enable_regedit_String_Termination" -eq 1; then
patch_apply regedit-String_Termination/0001-regedit-Avoid-appending-and-0-to-string-value-of-imp.patch
(
echo '+ { "Jiaxing Wang", "regedit: Avoid appending '\''\\\\0'\'' to string value of imported key.", 1 },';
) >> "$patchlist"
fi
# Patchset riched20-IText_Interface
# |
# | This patchset fixes the following Wine bugs:
@ -2755,21 +2774,6 @@ if test "$enable_winebuild_LinkerVersion" -eq 1; then
) >> "$patchlist"
fi
# Patchset wined3d-Color_Key
# |
# | This patchset fixes the following Wine bugs:
# | * [#37748] Fix color key regression causing pink rectangles around text
# |
# | Modified files:
# | * dlls/wined3d/surface.c
# |
if test "$enable_wined3d_Color_Key" -eq 1; then
patch_apply wined3d-Color_Key/0001-wined3d-Use-proper-color-key-type-define-when-callin.patch
(
echo '+ { "Christian Costa", "wined3d: Use proper color key type define when calling wined3d_texture_set_color_key.", 1 },';
) >> "$patchlist"
fi
# Patchset wined3d-CSMT_Helper
# |
# | Modified files:
@ -2786,6 +2790,21 @@ if test "$enable_wined3d_CSMT_Helper" -eq 1; then
) >> "$patchlist"
fi
# Patchset wined3d-Color_Key
# |
# | This patchset fixes the following Wine bugs:
# | * [#37748] Fix color key regression causing pink rectangles around text
# |
# | Modified files:
# | * dlls/wined3d/surface.c
# |
if test "$enable_wined3d_Color_Key" -eq 1; then
patch_apply wined3d-Color_Key/0001-wined3d-Use-proper-color-key-type-define-when-callin.patch
(
echo '+ { "Christian Costa", "wined3d: Use proper color key type define when calling wined3d_texture_set_color_key.", 1 },';
) >> "$patchlist"
fi
# Patchset wined3d-CSMT_Main
# |
# | This patchset fixes the following Wine bugs:

View File

@ -0,0 +1,38 @@
From ec88679b1ecd54f40dccaf374ca21bb96441a18a Mon Sep 17 00:00:00 2001
From: Jiaxing Wang <hello.wjx@gmail.com>
Date: Thu, 20 Nov 2014 15:29:07 +0800
Subject: regedit: Avoid appending '\0' to string value of imported key.
After importing, string values are appended with '\0'.
For example, importing:
[HKEY_LOCAL_MACHINE\testkey]
"value"="abc"
gets
[HKEY_LOCAL_MACHINE\testkey]
"value"="abc\0"
This is because the null character after last quote is included
which is not needed as the last quote has been changed to '\0' and
dwLen already include the last quote.
---
programs/regedit/regproc.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/programs/regedit/regproc.c b/programs/regedit/regproc.c
index 80beb21..643b559 100644
--- a/programs/regedit/regproc.c
+++ b/programs/regedit/regproc.c
@@ -376,7 +376,6 @@ static LONG setValue(WCHAR* val_name, WCHAR* val_data, BOOL is_unicode)
return ERROR_INVALID_DATA;
val_data[dwLen-1] = '\0'; /* remove last quotes */
lpbData = (BYTE*) val_data;
- dwLen++; /* include terminating null */
dwLen = dwLen * sizeof(WCHAR); /* size is in bytes */
}
else if (dwParseType == REG_DWORD) /* Convert the dword types */
--
2.2.1

View File

@ -0,0 +1 @@
Fixes: [37575] Do not append duplicate NULL characters when importing keys with regedit