New user registration is currently disabled due to spam abuse / Регистрация новых пользователей в настоящее время приостановлена из-за злоупотреблений спаммерами

Request Enocodings for Web Searches: Big-5 and GB18030

General discussion

Re: Request Enocodings for Web Searches: Big-5 and GB18030

Postby Tvangeste » Sat Jul 30, 2011 6:34 pm

michaelopt wrote:Would you mind compiling a debugging mode GD and uploading it? I would try to get a error log for the crash.


Here it is: http://www.multiupload.com/OM91EB0Z7X

It is not that small (71mb), due to big debugging libraries.
Tvangeste
 
Posts: 893
Joined: Thu Jun 02, 2011 11:42 am

Re: Request Enocodings for Web Searches: Big-5 and GB18030

Postby Tvangeste » Sat Jul 30, 2011 6:42 pm

michaelopt wrote:For your reference, my machine is running Windows 7 Ultimate x64.

Good, I'm running the same! :)

Tvangeste wrote:
michaelopt wrote:Incidentally, is there any way to print the error log of the crash?

The best way to investigate the crash is to build GoldenDict in Debug mode, and then strat it from within gdb, like this:

michaelopt wrote:Thanks for your guide. However it seems that I am really a layman in compiling Qt programs. Is there any reference that I could follow straight so as to avoid some hilarious results?


I would really recommend to use Qt Creator and build GoldenDict right from Qt Creator. Basically, download the Qt SDK installer: http://qt.nokia.com/downloads/sdk-windows-cpp , and then run it to install Qt Creator + MinGW + Qt libs + GDB, everything is in one package, which is rather convenient.

Once everything is installed, start the Qt Creator, open goldendict.pro file (do NOT select shadow build option, when prompted). Once the GoldenDict project is loaded, select the debug mode and build goldendict.exe (which should reside in debug folder). In order to properly function, this goldendict.exe executable needs the debugging Qt DLLs, all those DLLs are in the debug package I posted earlier.
Tvangeste
 
Posts: 893
Joined: Thu Jun 02, 2011 11:42 am

Re: Request Enocodings for Web Searches: Big-5 and GB18030

Postby michaelopt » Sun Jul 31, 2011 8:41 am

Hi I just captured the debugging information from the GDB about the crash:

Code: Select all
Microsoft Windows [版本 6.1.7601]
Copyright (c) 2009 Microsoft Corporation.  All rights reserved.

D:\Admin\Downloads>C:

C:\>cd \MinGW\bin

C:\MinGW\bin>gdb D:\GoldenDict.Debug.To.Try\goldendict.exe
GNU gdb (GDB) 7.2
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "mingw32".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from D:\GoldenDict.Debug.To.Try\goldendict.exe...done.
(gdb) run
Starting program: D:\GoldenDict.Debug.To.Try\goldendict.exe
[New Thread 4224.0x161c]
QObject::connect: Connecting from COMPAT signal (QAction::activated())
QObject::connect: Connecting from COMPAT signal (QAction::activated())
QObject::connect: Connecting from COMPAT signal (QAction::activated())
QObject::connect: Connecting from COMPAT signal (QAction::activated())
QObject::connect: Connecting from COMPAT signal (QAction::activated())
QObject::connect: Connecting from COMPAT signal (QAction::activated())
QObject::connect: Connecting from COMPAT signal (QAction::activated())
QObject::connect: Connecting from COMPAT signal (QAction::activated())
QObject::connect: Connecting from COMPAT signal (QAction::activated())
QObject::connect: Connecting from COMPAT signal (QAction::activated())
QObject::connect: Connecting from COMPAT signal (QAction::activated())
[New Thread 4224.0x43c]
Dictionary name:
Alt headword: '
Alt headword: '
Alt headword: '
DSL dictionary reading failed: D:\Admin\軟件\Dictionaries\21世紀英漢漢英雙向詞典
\21shijishuangxiangcidian-big5.dsl:5, error: Invalid character sequence encounte
red during character convesion
Dictionary name:
Alt headword: (
Alt headword: (
Alt headword: (
Alt headword: (
Alt headword: (
Alt headword: (
Alt headword: (
Alt headword: (
Alt headword: (
Alt headword: (
Alt headword: (
Alt headword: (
Alt headword: -
Alt headword: -
Alt headword: 0
Alt headword: 0
Alt headword: 0
Alt headword: 1
Alt headword: 1
Alt headword: 1
Alt headword: 1
Alt headword: 1
Alt headword: 1
Alt headword: 1
Alt headword: 1
Alt headword: 1
Alt headword: 1
DSL dictionary reading failed: D:\Admin\軟件\Dictionaries\21世紀雙語科技詞典\21s
hijishuangyukejicidian-big5.dsl:29, error: Invalid character sequence encountere
d during character convesion
Dictionary name:
Alt headword: Alt headword: Alt headword: Alt headword: Alt headword: Alt headwo
rd: Alt headword: Alt headword: Alt headword: Alt headword: DSL dictionary readi
ng failed: D:\Admin\軟件\Dictionaries\朗道漢英字典\langdao-ce-big5.dsl:12, error
: Invalid character sequence encountered during character convesion
DSL dictionary reading failed: D:\Admin\軟件\Dictionaries\牛津英漢雙解詞典\oxfor
d-big5.dsl:0, error: Invalid character sequence encountered during character con
vesion
Load done
[New Thread 4224.0x814]
getResource: gdlookup://localhost?blank=1
scheme: gdlookup
host: localhost
[New Thread 4224.0x12b8]
[New Thread 4224.0x17a8]
[New Thread 4224.0x14c0]
[New Thread 4224.0x1354]
getResource: gdlookup://localhost?blank=1
scheme: gdlookup
host: localhost
getResource: gdlookup://localhost?word=scheme: gdlookup
host: localhost
In-place finish.
[New Thread 4224.0x16b4]
[New Thread 4224.0xffc]
Loading 24 abbrv
====reading 54644 bytes
Loading 5 abbrv
Loading 126 abbrv
Loading 3 abbrv
Loading 22 abbrv
Loading 22 abbrv
Loading 4 abbrv
Loading 27 abbrv
Loading 94 abbrv
Loading 65 abbrv
Loading 30 abbrv
request begin
[New Thread 4224.0x8e8]
request begin
[New Thread 4224.0x1620]
not long enough
not long enough
request end
[New Thread 4224.0x148c]
request end
request begin
request begin
[New Thread 4224.0x4ac]
not long enough
not long enough
request end
request end
request begin
request begin
[New Thread 4224.0x11d4]
request end
request end
request begin
request begin
done.
done.
request end
request end
getResource: gdlookup://localhost?word=test&group=1
scheme: gdlookup
host: localhost
====reading 53499 bytes
alts finished
Requesting article t
Requesting article t

Program received signal SIGSEGV, Segmentation fault.
0x6a22fb7d in QTextCodec::fromUnicode (this=0x0, str=...)
    at c:\ndk_buildrepos\qt-desktop\src\corelib\codecs\qtextcodec.cpp:1379
1379    c:\ndk_buildrepos\qt-desktop\src\corelib\codecs\qtextcodec.cpp: No such
file or directory.
        in c:\ndk_buildrepos\qt-desktop\src\corelib\codecs\qtextcodec.cpp


The GDB reported that there was a segmentation fault.

As you suggested, I also ran a backtrace for it:

Code: Select all
(gdb) bt
#0  0x6a22fb7d in QTextCodec::fromUnicode (this=0x0, str=...)
    at c:\ndk_buildrepos\qt-desktop\src\corelib\codecs\qtextcodec.cpp:1379
#1  0x004c1ea3 in WebSite::(anonymous namespace)::WebSiteDictionary::getArticle
(this=0xe8a88c8, str=..., context=...) at website.cc:88
#2  0x0048c1e5 in ArticleRequest::altSearchFinished (this=0xf21f3f0)
    at article_maker.cc:332
#3  0x0050e97a in ArticleRequest::qt_metacall (this=0xf21f3f0,
    _c=QMetaObject::InvokeMetaMethod, _id=0, _a=0xe831910)
    at build/moc_article_maker.cpp:128
#4  0x6a205ff8 in QMetaObject::metacall (object=0xf21f3f0,
    cl=QMetaObject::InvokeMetaMethod, idx=6, argv=0xe831910)
    at c:\ndk_buildrepos\qt-desktop\src\corelib\kernel\qmetaobject.cpp:237
#5  0x6a210c9d in QMetaCallEvent::placeMetaCall (this=0xf006938,
    object=0xf21f3f0)
    at c:\ndk_buildrepos\qt-desktop\src\corelib\kernel\qobject.cpp:535
#6  0x6a212ba8 in QObject::event (this=0xf21f3f0, e=0xf006938)
    at c:\ndk_buildrepos\qt-desktop\src\corelib\kernel\qobject.cpp:1217
#7  0x025cbd88 in QApplicationPrivate::notify_helper (this=0xca51f80,
    receiver=0xf21f3f0, e=0xf006938)
    at c:\ndk_buildrepos\qt-desktop\src\gui\kernel\qapplication.cpp:4462
#8  0x025c96da in QApplication::notify (this=0x28fe68, receiver=0xf21f3f0,
    e=0xf006938)
    at c:\ndk_buildrepos\qt-desktop\src\gui\kernel\qapplication.cpp:3862
#9  0x6a201540 in QCoreApplication::notifyInternal (this=0x28fe68,
    receiver=0xf21f3f0, event=0xf006938)
    at c:\ndk_buildrepos\qt-desktop\src\corelib\kernel\qcoreapplication.cpp:731
#10 0x6a268258 in QCoreApplication::sendEvent (receiver=0xf21f3f0,
    event=0xf006938)
    at c:/ndk_buildrepos/qt-desktop/src/corelib/kernel//qcoreapplication.h:215
#11 0x6a2025eb in QCoreApplicationPrivate::sendPostedEvents (receiver=0x0,
    event_type=0, data=0xca5ff48)
    at c:\ndk_buildrepos\qt-desktop\src\corelib\kernel\qcoreapplication.cpp:1372

#12 0x6a2248e7 in qt_internal_proc (hwnd=0x7094a, message=1025, wp=0, lp=0)
    at c:\ndk_buildrepos\qt-desktop\src\corelib\kernel\qeventdispatcher_win.cpp:
497
#13 0x755a62fa in USER32!OffsetRect () from C:\Windows\syswow64\user32.dll
#14 0x0007094a in ?? ()
warning: (Internal error: pc 0x400 in read in psymtab, but not in symtab.)

warning: (Internal error: pc 0x400 in read in psymtab, but not in symtab.)

#15 0x00000401 in ?? (warning: (Internal error: pc 0x400 in read in psymtab, but
 not in symtab.)

)
    at r:/soft/qt/mingw/bin/../lib/gcc/mingw32/4.4.0/include/c++/bits/vector.tcc
:437
warning: (Internal error: pc 0x400 in read in psymtab, but not in symtab.)

#16 0x00000000 in ?? ()
(gdb)


Wow I have to confess that programming and debugging are difficult tasks. When I looked at the backtrace, I had no idea what it was referring to and I was simply innocent.

Tvangeste wrote:I would really recommend to use Qt Creator and build GoldenDict right from Qt Creator. Basically, download the Qt SDK installer: http://qt.nokia.com/downloads/sdk-windows-cpp , and then run it to install Qt Creator + MinGW + Qt libs + GDB, everything is in one package, which is rather convenient.

Once everything is installed, start the Qt Creator, open goldendict.pro file (do NOT select shadow build option, when prompted). Once the GoldenDict project is loaded, select the debug mode and build goldendict.exe (which should reside in debug folder). In order to properly function, this goldendict.exe executable needs the debugging Qt DLLs, all those DLLs are in the debug package I posted earlier.


Yes I agree that we should compile the sources on Qt Creator first. I did try to open the goldendict.pro file on Qt Creator right after installing the Qt Creator, but the Qt Creator froze and crashed. I then had no way but to only use the qmake to compile it. Somehow I tried opening the project again from the Qt Creator this morning and it loaded successfully! I guess I missed a restart after installing Qt Creator.
michaelopt
 
Posts: 8
Joined: Sat Jul 23, 2011 1:49 pm

Re: Request Enocodings for Web Searches: Big-5 and GB18030

Postby Abs62 » Sun Jul 31, 2011 9:19 am

Try find next string in website.cc:
Code: Select all
    urlString.replace( "%25GDBIG5%25",
                       QTextCodec::codecForName( "Big-5" )->fromUnicode( inputWord ).toPercentEncoding() );

and change "Big-5" to "Big5".
Abs62
 
Posts: 627
Joined: Mon Jun 14, 2010 11:51 am

Re: Request Enocodings for Web Searches: Big-5 and GB18030

Postby michaelopt » Wed Aug 03, 2011 3:19 am

Sorry for my late reply, I was busy tackling school tests.

Abs62 wrote:Try find next string in website.cc:
Code: Select all
    urlString.replace( "%25GDBIG5%25",
                       QTextCodec::codecForName( "Big-5" )->fromUnicode( inputWord ).toPercentEncoding() );

and change "Big-5" to "Big5".


As I mentioned earlier, I had encountered some strange errors when using Qt Creator, which was installed separately from the Qt Libraries and MinGW. As Tvangeste had advised me to install the Qt SDK, I uninstalled all the seperately installed development libraries and environment, and installed the Qt SDK.

And thanks to Tvangeste's suggestion, now the Qt Creator works like a charm! I did according to Abs62's instructions to modify the website.cc and built new binary. Unluckily, it still crashed. The following is a new log and back trace of the new built binary crash printed by GDB:

Code: Select all
Microsoft Windows [版本 6.1.7601]
Copyright (c) 2009 Microsoft Corporation.  All rights reserved.

D:\Admin\Downloads>C:

C:\>cd QtSDK\pythongdb\python_2.7based\

C:\QtSDK\pythongdb\python_2.7based>gdb-i686-pc-mingw32 "D:\GoldenDict.Debug.To.T
ry\goldendict.exe"
GNU gdb (GDB) 7.2
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "i686-pc-mingw32".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from D:\GoldenDict.Debug.To.Try\goldendict.exe...done.
(gdb) run
Starting program: D:\GoldenDict.Debug.To.Try\goldendict.exe
[New Thread 3980.0x7cc]
QObject::connect: Connecting from COMPAT signal (QAction::activated())
QObject::connect: Connecting from COMPAT signal (QAction::activated())
QObject::connect: Connecting from COMPAT signal (QAction::activated())
QObject::connect: Connecting from COMPAT signal (QAction::activated())
QObject::connect: Connecting from COMPAT signal (QAction::activated())
QObject::connect: Connecting from COMPAT signal (QAction::activated())
QObject::connect: Connecting from COMPAT signal (QAction::activated())
QObject::connect: Connecting from COMPAT signal (QAction::activated())
QObject::connect: Connecting from COMPAT signal (QAction::activated())
QObject::connect: Connecting from COMPAT signal (QAction::activated())
QObject::connect: Connecting from COMPAT signal (QAction::activated())
[New Thread 3980.0xc4c]
Dictionary name:
Alt headword: '
Alt headword: '
Alt headword: '
DSL dictionary reading failed: D:\Admin\軟件\Dictionaries\21世紀英漢漢英雙向詞典
\21shijishuangxiangcidian-big5.dsl:5, error: Invalid character sequence encounte
red during character convesion
Dictionary name:
Alt headword: (
Alt headword: (
Alt headword: (
Alt headword: (
Alt headword: (
Alt headword: (
Alt headword: (
Alt headword: (
Alt headword: (
Alt headword: (
Alt headword: (
Alt headword: (
Alt headword: -
Alt headword: -
Alt headword: 0
Alt headword: 0
Alt headword: 0
Alt headword: 1
Alt headword: 1
Alt headword: 1
Alt headword: 1
Alt headword: 1
Alt headword: 1
Alt headword: 1
Alt headword: 1
Alt headword: 1
Alt headword: 1
DSL dictionary reading failed: D:\Admin\軟件\Dictionaries\21世紀雙語科技詞典\21s
hijishuangyukejicidian-big5.dsl:29, error: Invalid character sequence encountere
d during character convesion
Dictionary name:
Alt headword: Alt headword: Alt headword: Alt headword: Alt headword: Alt headwo
rd: Alt headword: Alt headword: Alt headword: Alt headword: DSL dictionary readi
ng failed: D:\Admin\軟件\Dictionaries\朗道漢英字典\langdao-ce-big5.dsl:12, error
: Invalid character sequence encountered during character convesion
DSL dictionary reading failed: D:\Admin\軟件\Dictionaries\牛津英漢雙解詞典\oxfor
d-big5.dsl:0, error: Invalid character sequence encountered during character con
vesion
Load done
[New Thread 3980.0x113c]
getResource: gdlookup://localhost?blank=1
scheme: gdlookup
host: localhost
[New Thread 3980.0x16f0]
[New Thread 3980.0xfec]
[New Thread 3980.0x16fc]
[New Thread 3980.0x10f0]
getResource: gdlookup://localhost?blank=1
scheme: gdlookup
host: localhost
getResource: gdlookup://localhost?word=scheme: gdlookup
host: localhost
In-place finish.
[New Thread 3980.0x258]
[New Thread 3980.0xe78]
Loading 24 abbrv
Loading 126 abbrv
Loading 5 abbrv
Loading 3 abbrv
Loading 22 abbrv
Loading 22 abbrv
Loading 4 abbrv
Loading 94 abbrv
Loading 65 abbrv
Loading 27 abbrv
Loading 30 abbrv
====reading 56356 bytes
getResource: gdlookup://localhost?blank=1
scheme: gdlookup
host: localhost
request begin
request begin
[New Thread 3980.0x12cc]
[New Thread 3980.0x16ec]
[New Thread 3980.0x1078]
done.
done.
request end
request end
request begin
request begin
done.
done.
request end
request end
request begin
request begin
request end
request end
request begin
[New Thread 3980.0x1760]
request begin
not long enough
not long enough
request end
request end
request begin
request begin
getResource: gdlookup://localhost?word=test&group=1
scheme: gdlookup
host: localhost
====reading 55211 bytes
alts finished
Requesting article t
Requesting article t

Program received signal SIGSEGV, Segmentation fault.
0x6a22fb7d in QTextCodec::fromUnicode (this=0x0, str=...)
    at c:\ndk_buildrepos\qt-desktop\src\corelib\codecs\qtextcodec.cpp:1379
1379    c:\ndk_buildrepos\qt-desktop\src\corelib\codecs\qtextcodec.cpp: No such
file or directory.
        in c:\ndk_buildrepos\qt-desktop\src\corelib\codecs\qtextcodec.cpp
(gdb) bt
#0  0x6a22fb7d in QTextCodec::fromUnicode (this=0x0, str=...)
    at c:\ndk_buildrepos\qt-desktop\src\corelib\codecs\qtextcodec.cpp:1379
#1  0x004c1f83 in WebSite::(anonymous namespace)::WebSiteDictionary::getArticle
(this=0xeb4d660, str=..., context=...) at website.cc:88
#2  0x0048c259 in ArticleRequest::altSearchFinished (this=0xecb1b48)
    at article_maker.cc:338
#3  0x0050eb2a in ArticleRequest::qt_metacall (this=0xecb1b48,
    _c=QMetaObject::InvokeMetaMethod, _id=0, _a=0xeb9c7b8)
    at build\moc_article_maker.cpp:128
#4  0x6a205ff8 in QMetaObject::metacall (object=0xecb1b48,
    cl=QMetaObject::InvokeMetaMethod, idx=6, argv=0xeb9c7b8)
    at c:\ndk_buildrepos\qt-desktop\src\corelib\kernel\qmetaobject.cpp:237
#5  0x6a210c9d in QMetaCallEvent::placeMetaCall (this=0xec2ec98,
    object=0xecb1b48)
    at c:\ndk_buildrepos\qt-desktop\src\corelib\kernel\qobject.cpp:535
#6  0x6a212ba8 in QObject::event (this=0xecb1b48, e=0xec2ec98)
    at c:\ndk_buildrepos\qt-desktop\src\corelib\kernel\qobject.cpp:1217
#7  0x0278bd88 in QApplicationPrivate::notify_helper (this=0xcc61f70,
    receiver=0xecb1b48, e=0xec2ec98)
    at c:\ndk_buildrepos\qt-desktop\src\gui\kernel\qapplication.cpp:4462
#8  0x027896da in QApplication::notify (this=0x28fe68, receiver=0xecb1b48,
    e=0xec2ec98)
    at c:\ndk_buildrepos\qt-desktop\src\gui\kernel\qapplication.cpp:3862
#9  0x6a201540 in QCoreApplication::notifyInternal (this=0x28fe68,
    receiver=0xecb1b48, event=0xec2ec98)
    at c:\ndk_buildrepos\qt-desktop\src\corelib\kernel\qcoreapplication.cpp:731
#10 0x6a268258 in QCoreApplication::sendEvent (receiver=0xecb1b48,
    event=0xec2ec98)
    at c:/ndk_buildrepos/qt-desktop/src/corelib/kernel//qcoreapplication.h:215
#11 0x6a2025eb in QCoreApplicationPrivate::sendPostedEvents (receiver=0x0,
    event_type=0, data=0xcc62090)
    at c:\ndk_buildrepos\qt-desktop\src\corelib\kernel\qcoreapplication.cpp:1372

#12 0x6a2248e7 in qt_internal_proc (hwnd=0x305d0, message=1025, wp=0, lp=0)
    at c:\ndk_buildrepos\qt-desktop\src\corelib\kernel\qeventdispatcher_win.cpp:
497
#13 0x765162fa in USER32!OffsetRect () from C:\Windows\syswow64\user32.dll
#14 0x000305d0 in ?? ()
#15 0x76516d3a in USER32!IsWindow () from C:\Windows\syswow64\user32.dll
#16 0x6a22467e in qt_fast_timer_proc (timerId=0, user=198096)
    at c:\ndk_buildrepos\qt-desktop\src\corelib\kernel\qeventdispatcher_win.cpp:
429
#17 0x765177c4 in USER32!AnyPopup () from C:\Windows\syswow64\user32.dll
#18 0x00000000 in ?? ()
(gdb)


The log looks very alike to the previous one which I have copied, so it seems that the Big5 wrong spelling is not the cause of the crash. Perhaps we have to probe further into it for getting rid of the crash.
michaelopt
 
Posts: 8
Joined: Sat Jul 23, 2011 1:49 pm

Re: Request Enocodings for Web Searches: Big-5 and GB18030

Postby Tvangeste » Wed Aug 03, 2011 7:16 am

Interesting. Anything particular you're trying to enter when the crash happens? Or does it crash an *any* kind of input?
Tvangeste
 
Posts: 893
Joined: Thu Jun 02, 2011 11:42 am

Re: Request Enocodings for Web Searches: Big-5 and GB18030

Postby michaelopt » Wed Aug 03, 2011 5:57 pm

Tvangeste wrote:Interesting. Anything particular you're trying to enter when the crash happens? Or does it crash an *any* kind of input?


I have tested different conditions. No matter I enter English words or Chinese characters, whenever there is one or more online dictionaries activated (either the default ones like Urban Dictionary, or the ones that I added myself; whether the online dictionaries use string %GDWORD% or %GDBIG5%), if the present query is input into a group which includes the activated online dictionaries, it crashes when you press Enter. During entering the characters, the left word list could respond normally. As said, as long as the querying word is not searched from the activated online dictionaries' group, it still would not crash.

The version that I am using without crash is the "GoldenDict-1.0.1-68-g7525e45", which should be a built that has not been implemented the "%GDBIG5%" yet. I tried to run the newly built binary right in that folder, it still crashed.

Currently my bug free "GoldenDict-1.0.1-68-g7525e45" is running in Portable Mode as I failed to make the CSSs work in Normal Mode. During the trials I have tried both modes see if there was a chance that the new built could go through the crash, but unfortunately no.

I discovered that the binary of the "GoldenDict-1.0.1-68-g7525e45" was named as "GoldenDict.exe", while the new compiled was named as "goldendict.exe". I renamed the new with the old's style, but still no luck.

I also noticed that the new binary asked for "libiconv-2.dll" instead of "libiconv2.dll" which is used by the old. I tried renaming the old "libiconv2.dll" to suit for the new binary, no luck; copying the "genuine" "libiconv-2.dll" from "C:\QtSDK\mingw\bin\libiconv-2.dll", crash persists.

I have also removed all my own entries of online dictionaries, solely for trying the default Google En-En and Urban Dictionary respectively. Both crash at the end.

Copied the whole folder to the top of the D:\, but still crashes when run.

To prove that the libraries attached to the latest built "GoldenDict-1.0.1-145-gc5693df" are all good, I copied the old executable to that folder and renamed the "libiconv-2.dll" to "libiconv2.dll", GD runs flawlessly.

You may suggest me any other way which could avoid the bug or find the cause of the crash. I am glad to help.
michaelopt
 
Posts: 8
Joined: Sat Jul 23, 2011 1:49 pm

Re: Request Enocodings for Web Searches: Big-5 and GB18030

Postby Abs62 » Thu Aug 04, 2011 1:13 pm

michaelopt wrote:I copied the old executable to that folder

Old executable don't know about %GDBIG5% field in urls.

Try create folder "codecs" in your GD folder, then copy to it 4 dll's from "plugins\codecs" folder in your QT installation. ...codecs4.dll for release build of GD or ...codecs4d.dll for debug build.
Abs62
 
Posts: 627
Joined: Mon Jun 14, 2010 11:51 am

Re: Request Enocodings for Web Searches: Big-5 and GB18030

Postby michaelopt » Thu Aug 04, 2011 5:19 pm

Abs62 wrote:Try create folder "codecs" in your GD folder, then copy to it 4 dll's from "plugins\codecs" folder in your QT installation. ...codecs4.dll for release build of GD or ...codecs4d.dll for debug build.


Oh you are right! After I copied the "codecs" folder from "C:\QtSDK\Desktop\Qt\4.7.3\mingw\plugins\codecs" to the folder where the new executable was located, I activated those online dictionaries and executed the queries, and it does not crash any more!

I have also tried both executables which were built from the "Big-5" and "Big5" coded in "website.cc". Both could now run smoothly as long as the "codecs" folder presents.

I added three online dictionaries which use Big-5 coding. Two of them display pages correctly, the remaining one somehow shows some wrong symbols. However I have scrutinized the spelling of the HTTP address and the HTTP parameters of that dictionary, all are correct. And from the page content displayed, I could see that GD is actually loading a correct page by translating my Chinese character into Big-5 codes and put it into the HTTP address. But very strange GD fails to further display the result page in Big-5 again.

For your reference, the address of the aforesaid wrongly displayed online dictionary is:
Code: Select all
http://humanum.arts.cuhk.edu.hk/cgi-bin/canton-new.pl?query=%GDBIG5%

For me now I already feel very satisfied. But if you want to make GD perfect you could have a look on it.

Tvangeste wrote:P.S. As for GB 18030, could you please provide some URLs where this can be used (and tested)? I haven't added this one yet, since I cannot test it.


I feel sorry about suggesting the implementation of GB18030 encoding as I cannot find any online dictionary which is currently using it. Most of the Simplified Chinese online dictionaries are already running UTF-8, and the number of Traditional Chinese online dictionaries are substantially more than that of Simplified Chinese. So even you have implemented it I currently have no source to try it.

By the way, is there anyway to let us browse further the online dictionaries by clicking its hyperlinks? When I click them GD just use the whole link literally to launch a new query. I guess there is a hotkey which, when you click the hyperlink while pressing it down, could suspend the original new query function and make GD visit another web page like a browser does.
michaelopt
 
Posts: 8
Joined: Sat Jul 23, 2011 1:49 pm

Re: Request Enocodings for Web Searches: Big-5 and GB18030

Postby wuw » Thu Sep 01, 2011 6:48 am

michaelopt wrote:...After I copied the "codecs" folder from "C:\QtSDK\Desktop\Qt\4.7.3\mingw\plugins\codecs" to the folder where the new executable was located, I activated those online dictionaries and executed the queries, and it does not crash any more!
...

Can someone share these codecs?
wuw
 
Posts: 4
Joined: Thu Aug 18, 2011 5:51 pm

PreviousNext

Return to General

Who is online

Users browsing this forum: No registered users and 4 guests

cron