Hi again,
there is another bug in ResText when translating strings containing
backslashes. The backslash is not converted into a double backslash and
therefore the msgmerge utility will fail.
Attached is a small fix
Best regards
Dirk
Index: C:/src/tortoiseSVN/src/ResText/Utils.cpp
===================================================================
--- C:/src/tortoiseSVN/src/ResText/Utils.cpp (revision 5619)
+++ C:/src/tortoiseSVN/src/ResText/Utils.cpp (working copy)
@@ -29,7 +29,20 @@
void CUtils::StringExtend(LPTSTR str)
{
TCHAR * cPos = str;
- do
+ do
+ {
+ cPos = _tcschr(cPos, '\\');
+ if (cPos)
+ {
+ memmove(cPos+1, cPos, _tcslen(cPos)*sizeof(TCHAR));
+ *cPos = '\\';
+ *(cPos+1) = '\\';
+ cPos++;
+ cPos++;
+ }
+ } while (cPos != NULL);
+ cPos = str;
+ do
{
cPos = _tcschr(cPos, '\n');
if (cPos)
@@ -104,10 +117,12 @@
*cPos = '"';
memmove(cPos+1, cPos+2, (_tcslen(cPos+2)+1)*sizeof(TCHAR));
}
- else
- {
- cPos++;
- }
+ else if (*(cPos+1) == '\\')
+ {
+ *cPos = '\\';
+ memmove(cPos+1, cPos+2, (_tcslen(cPos+2)+1)*sizeof(TCHAR));
+ }
+ cPos++;
}
} while (cPos != NULL);
}
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tortoisesvn.tigris.org
For additional commands, e-mail: users-help@tortoisesvn.tigris.org
Received on Fri Feb 3 22:05:03 2006