WineHQ
Bug Tracking Database – Bug 34564

 Bugzilla

 

Last modified: 2013-11-15 13:40:42 UTC  

RTX Server fail to import user template database with builtin msvcp60

Bug 34564 - RTX Server fail to import user template database with builtin msvcp60
RTX Server fail to import user template database with builtin msvcp60
Status: CLOSED FIXED
AppDB: Show Apps affected by this bug
Product: Wine
Classification: Unclassified
Component: msvcp
1.7.2
x86 Linux
: P2 normal
: ---
Assigned To: Mr. Bugs
http://dldir1.qq.com/foxmail/rtx/rtxs...
: download
Depends on: 34552
Blocks:
  Show dependency tree
 
Reported: 2013-09-21 10:37 UTC by Qian Hong
Modified: 2013-11-15 13:40 UTC (History)
1 user (show)

See Also:
Regression SHA1:
Fixed by SHA1: dbbe237985cdb645f9a1d0a223c62e24fa4cd6f0
Distribution: ---
Staged patchset:


Attachments
Log: last 150000 line of +relay,+nls,+msvcp,+seh,+tid trace (581.01 KB, application/x-gzip)
2013-09-21 10:37 UTC, Qian Hong
Details
fix for char_traits<wchar>::assign function (1014 bytes, patch)
2013-09-23 04:12 UTC, Piotr Caban
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Qian Hong 2013-09-21 10:37:42 UTC
Created attachment 46016 [details]
Log: last 150000 line of +relay,+nls,+msvcp,+seh,+tid trace

Hello, this is next of Bug 34552

1.
winetricks -q mfc42 vbrun6 mdac28 jet40 , workaround for several missing
components / functions.

2. import odbc registry from Windows to Wine

3. run the installer

The installer will auto start UserManager.exe at the last.

The first time UserManager.exe runs, it will ask to import a user template database, with native msvcp60 it success, with buitin it fails.

The relay log contains some related error messages like:
03fa:Call msvcrt.wcslen(003354ac L"Syntax error in string in query expres       sion ''????????????????g'.") ret=019a9066

The relay log show the query exp as:
L"Insert into Sys_user(ID,UserName,Name,       Pwd,Gender,UserVersion,UserRight,Mobile,Email,Phone,Face,UserType,Profile       OpenLevel,BuddyAuth,LastLogonTime,AuthType) values(1001,'Hunter','\674e\6       60e','',0,1,'????????????????g"

The UserRight field '????????????????g is suspect, according to log before, it sound like converted from \3030\3030\3030\3030

03fa:trace:nls:WideCharToMultiByte cp 0 L"Insert into Sys_user(ID,UserNam       e,Name,Pwd,Gender,UserVersion,UserRight,Mobile,Email,Phone,Face,UserType,       ProfileOpenLevel,BuddyAuth,LastLogonTime,AuthType) values(1001,'Hunter','       \674e\660e','',0,1,'\3030\3030\3030\3030\3030\3030\3030\3030\3030\3030\30       30\3030\3030\3030\3030\3030g\0000" -> "Insert into Sys_user(ID,UserName,N       ame,Pwd,Gender,UserVersion,UserRight,Mobile,Email,Phone,Face,UserType,Pro       fileOpenLevel,BuddyAuth,LastLogonTime,AuthType) values(1001,'Hunter','\xc       0\xee\xc3\xf7','',0,1,'????????????????g\x00", ret = 209


With native msvcp60, the UserRight field is converted to '00000000...' (don't remember how many zero), that sounds like an ASCII conversion from 0x30303030,0x30303030,...

Guess some msvcp60 call before is incorrect, but I don't know which, will attach related logs
Comment 1 Qian Hong 2013-09-21 10:40:00 UTC
Oh, forgot to said, I applied patch 99019 to patch 99021
Comment 2 Piotr Caban 2013-09-23 04:12:34 UTC
Created attachment 46034 [details]
fix for char_traits<wchar>::assign function

Could you please check if this patch fixes the bug? If it still doesn't work please attach a new log (from wine with this patch applied).
Comment 3 Qian Hong 2013-09-23 05:03:06 UTC
(In reply to comment #2)
> Created attachment 46034 [details]
> fix for char_traits<wchar>::assign function
> 
> Could you please check if this patch fixes the bug? If it still doesn't work
> please attach a new log (from wine with this patch applied).

Thanks the work, the patch fix the bug!

 
-static wchar_t* char_traits_wchar_assignn(wchar_t *str, MSVCP_size_t num, wchar_t c)
+static wchar_t* char_traits_wchar_assignn(wchar_t *str,
+        MSVCP_size_t num, wchar_t c)
 {
-    return memset(str, c, num);
+    MSVCP_size_t i;
+
+    for(i=0; i<num; i++)
+        str[i] = c;
+
+    return str;
 }

BTW, how about using wmemset()?
Comment 4 Qian Hong 2013-09-23 05:06:52 UTC
Looks like wmemset isn't C89 compatible, please ignore my last question :)
Comment 5 Piotr Caban 2013-09-24 15:37:33 UTC
The patch is in wine. Marking as fixed.
Comment 6 Alexandre Julliard 2013-09-27 13:41:51 UTC
Closing bugs fixed in 1.7.3.
Comment 7 Alexandre Julliard 2013-11-15 13:40:42 UTC
Removing 1.6.x milestone from bugs included in 1.6.1.


Privacy Policy
If you have a privacy inquiry regarding this site, please write to [email protected]

Hosted By CodeWeavers