User forums > Help

Unable to read source file

(1/8) > >>

LuiZiffer:
Hello there,

I just installed Code::Blocks on OpenSuse Leap 42.3 for Windows Subsystem (Windows 10 installed -> OpenSuse Sub).
I'm using wxWidgets version 3.0.4 nostl.
When I try to open an existing project I get the following error in the terminal:


--- Quote ---NativeParser::DoFullParsing(): AddProjectDefinedMacros failed!
NativeParser::DoFullParsing(): Adding cpp/c files to batch-parser
NativeParser::DoFullParsing(): Added 1 source file(s) for project 'test' to batch-parser...
NativeParser::CreateParser(): Finish creating a new parser for project 'test'
NativeParser::OnParserStart(): Starting batch parsing for project 'test'...
NativeParser::OnParserEnd(): Project 'test' parsing stage done!
Project 'test' parsing stage done (2 total parsed files, 245 tokens in 0 minute(s), 0.003 seconds).
SystemHeadersThread: /usr/include/c++/4.8/ , 4326
SystemHeadersThread: /usr/include/c++/4.8/x86_64-suse-linux/ , 23
SystemHeadersThread: /usr/include/c++/4.8/backward/ , 8
SystemHeadersThread: /usr/lib64/gcc/x86_64-suse-linux/4.8/include/ , 56
SystemHeadersThread: /usr/local/include/ , 162
SystemHeadersThread: /usr/lib64/gcc/x86_64-suse-linux/4.8/include-fixed/ , 3
SystemHeadersThread: /usr/x86_64-suse-linux/include/ , 0
SystemHeadersThread: /usr/include/ , 16359
SystemHeadersThread: Total number of paths: 8
Final encoding detected: Unicode 8 bit (UTF-8) (ID: 43)
Encoding conversion has failed (buffer is empty)!
Something seriously went wrong while converting file content to wxString!
--- End quote ---

The Project is called "test" and has one source file: main.c. In Code::Blocks main.c only shows an empty file.
I can write and save but closing and opening a file makes the content disappear.
I used cat /path/to/project/main.c, and it displays everything I have written so far.

BlueHazzard:
What language do you use? What encoding is the file? Does it also happen if you save it as utf-8 file?

LuiZiffer:
file: main.c: text/plain; charset=us-ascii
Language: C/C++
I can save anything i write, but trying to re-open or read a file causes the above error and only shows an empty file

oBFusCATed:
What version of codeblocks are you using? Do you see the assert dialog?

BlueHazzard:

--- Quote ---Language: C/C++
--- End quote ---
By language i mean your system language and encoding...
Settings in Settings->Editor->Encoding settings?

Navigation

[0] Message Index

[#] Next page

Go to full version