User forums > Help

Unable to read source file

<< < (4/8) > >>

BlueHazzard:
After looking future in the code i found this in
sdk\encodingdetector.cpp:137

--- Code: ---
bool EncodingDetector::DetectEncoding(const wxString& filename, bool convert_to_wxstring)
{
[....]
   size_t readBytes = file.Read((void*)buffer, size);
    bool result = false;
    if (readBytes > 0)
        result = DetectEncoding(buffer, size, convert_to_wxstring);

--- End code ---
Shouldn't this be

--- Code: ---
   size_t readBytes = file.Read((void*)buffer, size);
    bool result = false;
    if (readBytes > 0)
        result = DetectEncoding(buffer, readBytes , convert_to_wxstring);

--- End code ---
?

Anyway this does not explain why later the size is 0....

LuiZiffer:
@BlueHazzard I did as described, the changes persist.

LuiZiffer:
As requested, screenshots are attached to this post.

oBFusCATed:
Ask bluehazzard mentioned the reason for the problem could be found only by making a debug and using a debugger.
My guess is that it is a combination of a cb and wx issue.
So you need to build both with debug information and do the stepping. :(

LuiZiffer:
@omlk Here you go (it didn't change anything)
@oBFusCATed so what can/should I do now?

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version