Hello.
I also don't see anything now, so forward the message to oi-dev for other developers to look it through. I would appreciate some reduced sample of broken code, which would allow us to test possible fixes...

By the way, do charset settings (character_set_client and other) and LC_* variables influence this crash?

On 08/09/2013 15:31, Gary Gendel wrote:
Alexander,

This is a program that I wrote for my company as part of the tool suite
we sell.  It run pulls out SQL files from an SCM and pipes them to mysql
(it's a mysql crash recovery program that gets the SCM and the metadata
stored in mysql in sync).

Recompiling doesn't help.  I must use the Sun compiler because the
vendor supplies the SCM C++ API is compiled with that.  I also ran it
under dbx with "check -all" enabled.  It stops here:

(dbx) cont
Reading libpthread.so.1
Write to read-only (wro) on thread 1:
Attempting to write 1 byte at address 0xee0bb35c
t@1 (l@1) stopped in my_xml_scan at 0xedf8adcc
0xedf8adcc: my_xml_scan+0x002c: testb $0x00000008,0xfffe0320(%ebx,%eax)
Current function is openMysql
   187       if (mysql_real_connect(conn, host, user, pw, db, port,
(dbx) where
current thread: t@1
   [1] my_xml_scan(0xf5d, 0xedf1d19c, 0xf31d0100, 0x0, 0x0, 0x3, 0xa,
0x8045ac4, 0xfefd2709, 0xee0db000, 0x80456c8, 0x4755, 0x80456a8,
0xfefc3330, 0xfeef0760, 0x960), at 0xedf8adcc
   [2] my_xml_parse(0x80456c8, 0x8139ce8, 0x4755, 0x0, 0x0, 0x0), at
0xedf8b36a
   [3] my_parse_charset_xml(0x8139ce8, 0x4755, 0xedf69470, 0x0,
0xfeffb0a4, 0x8046378), at 0xedf76d0f
   [4] 2(0xfe5012b9, 0xe04471c0, 0xedf6a2b0, 0x0, 0xfe501bb4,
0xfeffb0a4), at 0xedf69ef6
   [5] get_charset_by_csname(0x810c980, 0x20, 0x10, 0xfe511d88,
0xfe5012b9, 0xe04471c0), at 0xedf6a2dc
   [6] mysql_init_character_set(0x812a428, 0x812ec5f, 0xc, 0x0,
0x8046ae4, 0xf452fd73), at 0xedf8df9e
   [7] mysql_real_connect(0x812a428, 0x812699c, 0x8126bac, 0x8126cfc,
0x8126304, 0xd34), at 0xedf8ea5f
=>[8] openMysql(conn = 0x812a428, env = CLASS), line 187 in "libpm.cpp"
   [9] getLastLogSequence(env = CLASS), line 227 in "libpm.cpp"
   [10] main(argc = 3, argv = 0x80477d8), line 561 in "pmRestore.cpp"

So it' looks like it's crashing when reading xml returned by a mysql
server (version 5.5.28 running on a linux box).

Interestingly, my other programs that talk to Mysql through QT do not
exhibit this crash, so it may be likely that this is a compiler bug. The
program has been tested on Linux, Windows, and Mac without issue (and is
part of our regression suite). I've had to change the code on one
function in another program because the Sun compiler and the gcc
compiler disagree on the lifetime for a class returned by a function so
I passed it as an argument instead.  If no one else has reported such an
issue then I wouldn't kill myself over it.  However, I ran the
regression suite successfully with this program before I upgraded to
hipster.

This isn't critical as we don't support OpenIndiana or Solaris and I can
shut off the recovery tests in the regression suite to avoid the
crashes.  I just planned to use my OpenIndiana server as a continuous
build and test machine to free my desktop's mouse from being taken over
during the several hours of GUI testing.

The ldd of this program is:
     libmysqlclient.so.16 =>  /usr/mysql/lib/mysql/libmysqlclient.so.16
     libsocket.so.1 =>     /lib/libsocket.so.1
     libnsl.so.1 =>     /lib/libnsl.so.1
     libssl.so.0.9.8 =>     /lib/libssl.so.0.9.8
     libcrypto.so.0.9.8 =>     /lib/libcrypto.so.0.9.8
     libthread.so.1 =>     /lib/libthread.so.1
     librt.so.1 =>     /lib/librt.so.1
     libz.so.1 =>     /usr/lib/libz.so.1
     libCstd.so.1 =>     /usr/lib/libCstd.so.1
     libCrun.so.1 =>     /usr/lib/libCrun.so.1
     libm.so.2 =>     /lib/libm.so.2
     libc.so.1 =>     /lib/libc.so.1
     libpthread.so.1 =>     /lib/libpthread.so.1
     libgcc_s.so.1 =>     /usr/lib/libgcc_s.so.1
     libmp.so.2 =>     /lib/libmp.so.2
     libmd.so.1 =>     /lib/libmd.so.1

The ldd of another program that doesn't have the problem is:
     libsquishqtwrapper.so =>
  /usr/local/squish-5.0.0-qt-src/lib/libsquishqtwrapper.so
     libsquishhook.so =>
  /usr/local/squish-5.0.0-qt-src/lib/libsquishhook.so
     libqt-mt.so.3 =>     /usr/local/qt/lib/libqt-mt.so.3
     libmysqlclient.so.16 =>  /usr/mysql/lib/mysql/libmysqlclient.so.16
     libsocket.so.1 =>     /lib/libsocket.so.1
     libnsl.so.1 =>     /lib/libnsl.so.1
     libssl.so.0.9.8 =>     /lib/libssl.so.0.9.8
     libcrypto.so.0.9.8 =>     /lib/libcrypto.so.0.9.8
     libthread.so.1 =>     /lib/libthread.so.1
     librt.so.1 =>     /lib/librt.so.1
     libICE.so.6 =>     /usr/lib/libICE.so.6
     libSM.so.6 =>     /usr/lib/libSM.so.6
     libdl.so.1 =>     /lib/libdl.so.1
     libXext.so.0 =>     /usr/lib/libXext.so.0
     libX11.so.4 =>     /usr/lib/libX11.so.4
     libresolv.so.2 =>     /lib/libresolv.so.2
     libz.so.1 =>     /usr/lib/libz.so.1
     libCstd.so.1 =>     /usr/lib/libCstd.so.1
     libCrun.so.1 =>     /usr/lib/libCrun.so.1
     libm.so.2 =>     /lib/libm.so.2
     libc.so.1 =>     /lib/libc.so.1
     libpthread.so.1 =>     /lib/libpthread.so.1
     libdemangle.so.1 =>     /usr/lib/libdemangle.so.1
     libXtst.so.1 =>     /usr/lib/libXtst.so.1
     libGL.so.1 =>     /usr/lib/libGL.so.1
     libXmu.so.4 =>     /usr/lib/libXmu.so.4
     libXrender.so.1 =>     /usr/lib/libXrender.so.1
     libXrandr.so.2 =>     /usr/lib/libXrandr.so.2
     libXcursor.so.1 =>     /usr/lib/libXcursor.so.1
     libXinerama.so.1 =>     /usr/lib/libXinerama.so.1
     libXft.so.2 =>     /usr/lib/libXft.so.2
     libfreetype.so.6 =>     /usr/lib/libfreetype.so.6
     libfontconfig.so.1 =>     /usr/lib/libfontconfig.so.1
     libgcc_s.so.1 =>     /usr/lib/libgcc_s.so.1
     libmp.so.2 =>     /lib/libmp.so.2
     libmd.so.1 =>     /lib/libmd.so.1
     libXau.so.6 =>     /usr/lib/libXau.so.6
     libXdmcp.so.6 =>     /usr/lib/libXdmcp.so.6
     libXi.so.5 =>     /usr/lib/libXi.so.5
     libXxf86vm.so.1 =>     /usr/lib/libXxf86vm.so.1
     libXdamage.so.1 =>     /usr/lib/libXdamage.so.1
     libXfixes.so.1 =>     /usr/lib/libXfixes.so.1
     libdrm.so.2 =>     /usr/lib/xorg/libdrm.so.2
     libXt.so.4 =>     /usr/lib/libXt.so.4
     libXmuu.so.1 =>     /usr/lib/libXmuu.so.1
     libbz2.so.1 =>     /usr/lib/libbz2.so.1
     libexpat.so.1 =>     /usr/lib/libexpat.so.1
     libXevie.so.1 =>     /usr/lib/libXevie.so.1
     libXss.so.1 =>     /usr/lib/libXss.so.1

So nothing blatantly sticks out.



--
Best regards,
Alexander Pyhalov,
system administrator of Computer Center of Southern Federal University

_______________________________________________
oi-dev mailing list
[email protected]
http://openindiana.org/mailman/listinfo/oi-dev

Reply via email to