Care for NULL terminated strings in wine_dbgstr_xn

Uwe Bonnes bon at elektron.ikp.physik.tu-darmstadt.de
Sat May 4 13:45:04 CDT 2002


Changelog:
	dlls/ntdll/debugtools: wine_dbgstr_xn
	Try to determin length for zero-terminated strings

-- 
Uwe Bonnes                bon at elektron.ikp.physik.tu-darmstadt.de

Free Software: If you contribute nothing, expect nothing
--
Index: wine/dlls/ntdll/debugtools.c
===================================================================
RCS file: /home/wine/wine/dlls/ntdll/debugtools.c,v
retrieving revision 1.18
diff -u -r1.18 debugtools.c
--- wine/dlls/ntdll/debugtools.c	25 Apr 2002 21:40:56 -0000	1.18
+++ wine/dlls/ntdll/debugtools.c	4 May 2002 18:43:00 -0000
@@ -192,6 +192,8 @@
     old_pos = info->str_pos;
     __TRY
     {
+        if ( n == -1) /* we have to determin the length*/
+	     n = strlen(src);
         res = put_string_a( src, n );
     }
     __EXCEPT(page_fault)
@@ -223,6 +225,8 @@
     old_pos = info->str_pos;
     __TRY
     {
+        if ( n == -1) /* we have to determin the length*/
+	      n = lstrlenW(src);
         res = put_string_w( src, n );
     }
     __EXCEPT(page_fault)



More information about the wine-patches mailing list