#194 CEditFindReplaceImpl Bug

v1.0 (example)
open
None
5
2014-03-25
2007-12-07
akatsuki
No

in CEditFindReplaceImpl::FindTextSimple()

LPSTR lpch = (LPSTR)(lpsz + nLenFind);
char chSave = *lpch;

When _UNICODE is defined, this code cannot retrieve Japanese.
Therefore, it is necessary to do as follows.

LPTSTR lpch = (LPTSTR)(lpsz + nLenFind);
TCHAR chSave = *lpch;

Discussion

    • assigned_to: Nenad Stefanovic
    • Group: --> v1.0 (example)
     
  •  
  • It does seem like that, but casting doesn't change the original data. Testing shows that it works fine, even with Japanese characters. Do we really need to change something here?