Opened 14 years ago
Closed 14 years ago
#2419 closed bug (worksforme)
qgis standalone crashes when opening a vector layer with "Shift-JIS" encoding
Reported by: | toltec77 | Owned by: | nobody |
---|---|---|---|
Priority: | critical: causes crash or data corruption | Milestone: | Version 1.5.0 |
Component: | Build/Install | Version: | Trunk |
Keywords: | vector | Cc: | |
Must Fix for Release: | Yes | Platform: | All |
Platform Version: | Awaiting user input: | yes |
Description
Downloaded QGIS-1.4.0-1-No-GrassSetup.exe today. After installed and started the QGIS, A raster layer of Alaska sample data (landcover.img) opened OK, but the program shut down every time I tried to open a vector (lake.gml). Same thing happens when I tried to open my vector shapefiles.
Change History (11)
comment:1 by , 14 years ago
comment:2 by , 14 years ago
Summary: | unexpected shutdown when opening a vector layer → qgis standalone crashes when opening a vector layer with "Shift-JIS" encoding |
---|
Hi, this is replicable with the standalone installer but not with the osego4w one.
comment:4 by , 14 years ago
Component: | Build/Install → Data Provider |
---|
comment:5 by , 14 years ago
Platform: | Windows → All |
---|---|
Platform Version: | XP service pack 3 |
I was able to reproduce this on Mac OS X. I think it would be best if this was definitely fixed for the 1.5 release. I am looking at a crash dump though, and it is pointing at QtCore as the culprit of the crashing [QTextCodec::toUnicode(char const*) to be more specific].
follow-up: 7 comment:6 by , 14 years ago
Looks like a general protection fault in QTextCodec::toUnicode.
comment:7 by , 14 years ago
I am unable to reproduce this error when using "System" encoding on a Mac. I can only reproduce when I change the encoding from System to Shift-JIS. toltec77, does that work for you using System over Shift-JIS?
comment:8 by , 14 years ago
Ok, I have some more data:
Debug: /Users/ctimko/Documents/workspace/qgis/src/core/qgsvectordataprovider.cpp: 144: (setEncoding) error finding QTextCodec for SHIFT-JIS
Doesn't look like QTextCodec supports Japanese. This error was created when I set the encoding within xml as shift-jis.
Now, loading the file again with the shift-jis as the XML encoding, and I told the dialog to use System, this removed the error (of course), but it's attempt at parsing the file resulted in a crash. I will try with other foreign encodings.
comment:9 by , 14 years ago
This problem was talked in Japanese community. This issue is due to lack of Qt codec plug-in. OSGeo4w version has qt codec plugins at {OSGeo4w}/apps/qt4/plugins/codecs. But standalone version has no qt plugin about codecs. We addressed this issue by set the Qt codec plugins at the folder {QGIS}/bin/qtplugins/codecs.
To packeger, please include Qt plugins of codec to 1.5 new package.
comment:10 by , 14 years ago
Component: | Data Provider → Build/Install |
---|
comment:11 by , 14 years ago
Resolution: | → worksforme |
---|---|
Status: | new → closed |
Qt packaging issue - not a QGIS problem.
Update: it was related to encoding. The program works fine when encoding is "UTF-8," but fails when it is "Shift-JIS."