Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal / 2008-11

widestring related? problem on arm (2.3.1)

4 messages · 2 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Terry Kemp

I'm getting a runtime error 231 when starting program on arm. Stems from ANSI2WIDEMOVE in cwstring.pp returning ESysEBADF (9).

Do I need to define something on arm for widestrings?

Thanks

Terry

project2 -qws
[HINT] TWinControl.CreateWnd creating Handle during loading Form1:TForm1 csDesigning=False
[HINT] TWinControl.CreateWnd creating Handle during loading Panel2:TPanel csDesigning=False
[HINT] TWinControl.CreateWnd creating Handle during loading StatusBar1:TStatusBar csDesigning=False
[HINT] TWinControl.CreateWnd creating Handle during loading BitBtn4:TBitBtn csDesigning=False
[HINT] TWinControl.CreateWnd creating Handle during loading BitBtn1:TBitBtn csDesigning=False
[HINT] TWinControl.CreateWnd creating Handle during loading BitBtn7:TBitBtn csDesigning=False
[HINT] TWinControl.CreateWnd creating Handle during loading BitBtn8:TBitBtn csDesigning=False
[HINT] TWinControl.CreateWnd creating Handle during loading Panel3:TPanel csDesigning=False
Ansi2WideMove 9
Runtime error 231 at $0009D058
$0009D058 ANSI2WIDEMOVE, line 269 of ../unix/cwstring.pp $0002B654 fpc_char_to_uchar, line 644
of /build/gumstix/gumstix-fpc/fpc-svn/rtl/inc/ustrings.inc $0002BDC4 POS, line 1570
of /build/gumstix/gumstix-fpc/fpc-svn/rtl/inc/ustrings.inc $001B1EE8 TQTSTATICTEXT__SETTEXT, line 4177 of qtwidgets.pas $001A1018 TQTWSWINCONTROL__SETTEXT, line 360 of qtwscontrols.pp $000EA390 TWINCONTROL__WSSETTEXT, line 4754
of ./include/wincontrol.inc
$000EE974 TWINCONTROL__INITIALIZEWND, line 6615
of ./include/wincontrol.inc
$000EE484 TWINCONTROL__CREATEWND, line 6525
of ./include/wincontrol.inc
$000EDFD0 TWINCONTROL__CREATEHANDLE, line 6440
of ./include/wincontrol.inc
$000EF48C TWINCONTROL__HANDLENEEDED, line 6831
of ./include/wincontrol.inc

Reply by email

Jonas Maebe
to Terry Kemp
Terry Kemp wrote
I'm getting a runtime error 231 when starting program on arm. Stems from ANSI2WIDEMOVE in cwstring.pp returning ESysEBADF (9). Do I need to define something on arm for widestrings?

Run time error 231 in the unix wide string manager means that iconv returned an unexpected error code (in the sens that it's not supported by the code in the cwstring unit). Since you already compiled the cwstring unit with debug information, you can step into it (or set a breakpoint) and see what the error code is (or just add a writeln). Once you find out, it'll probably be easier to figure out what the problem is.

Jonas

Reply by email

Terry Kemp
to Jonas Maebe
Jonas Maebe wrote 14 lines
On 03 Nov 2008, at 01:06, Terry Kemp wrote: > I'm getting a runtime error 231 when starting program on arm. > Stems from ANSI2WIDEMOVE in cwstring.pp returning ESysEBADF (9). > > Do I need to define something on arm for widestrings? Run time error 231 in the unix wide string manager means that iconv returned an unexpected error code (in the sens that it's not supported by the code in the cwstring unit). Since you already compiled the cwstring unit with debug information, you can step into it (or set a breakpoint) and see what the error code is (or just add a writeln). Once you find out, it'll probably be easier to figure out what the problem is.

Thanks Jonas - the error no is 9 - ESysEBADF - System error: Bad file number.
The same code runs on x86_64 no probs and has been working on arm, but its been a month or so since I tried it on the arm hardware. I will install gdb on arm and see whats up.

Terry

Reply by email

Terry Kemp
to Jonas Maebe: Run time error 231 in the unix wide string manager means that iconv returned an…
Jonas Maebe wrote 20 lines
On 03 Nov 2008, at 01:06, Terry Kemp wrote: > I'm getting a runtime error 231 when starting program on arm. > Stems from ANSI2WIDEMOVE in cwstring.pp returning ESysEBADF (9). > > Do I need to define something on arm for widestrings? Run time error 231 in the unix wide string manager means that iconv returned an unexpected error code (in the sens that it's not supported by the code in the cwstring unit). Since you already compiled the cwstring unit with debug information, you can step into it (or set a breakpoint) and see what the error code is (or just add a writeln). Once you find out, it'll probably be easier to figure out what the problem is. Jonas _______________________________________________ fpc-pascal maillist - http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Hi

Attached is a gdb log.

The problem seems to be here...
fpc_char_to_uchar (C=38 '&') at ustrings.inc:644
644 widestringmanager.Ansi2UnicodeMoveProc(@c, w, 1); (gdb) p w
$18 = (WIDESTRING) 0x0

where w is suddenly undefined.

thoughts?

Terry

Reply by email