Commit in reactos/subsys/system/explorer/utility on MAIN
xmlstorage.h+6-21.30 -> 1.31
fix UTF8 conversion for the bookmarks list

reactos/subsys/system/explorer/utility
xmlstorage.h 1.30 -> 1.31
diff -u -r1.30 -r1.31
--- xmlstorage.h	26 Sep 2004 15:13:16 -0000	1.30
+++ xmlstorage.h	21 Nov 2004 22:42:51 -0000	1.31
@@ -234,8 +234,8 @@
 inline std::string get_utf8(LPCTSTR s, int l)
 {
 #ifdef UNICODE
-	LPSTR buffer = (LPSTR)alloca(l);
-	l = WideCharToMultiByte(CP_UTF8, 0, s, l, buffer, l, 0, 0);
+	int bl=2*l; LPSTR buffer = (LPSTR)alloca(bl);
+	l = WideCharToMultiByte(CP_UTF8, 0, s, l, buffer, bl, 0, 0);
 #else
 	LPWSTR wbuffer = (LPWSTR)alloca(sizeof(WCHAR)*l);
 	l = MultiByteToWideChar(CP_ACP, 0, s, l, wbuffer, l);
@@ -1629,7 +1629,11 @@
 		tifstream in(path);
 		XMLReader reader(this, in);
 
+//#if defined(_STRING_DEFINED) && !defined(XS_STRING_UTF8)
+//		return read(reader, std::string(ANS(path)));
+//#else
 		return read(reader, XS_String(path));
+//#endif
 	}
 
 	bool read(XMLReaderBase& reader)
CVSspam 0.2.8