Hi, the segmentation fault was due the fact, that the pstex driver never told the plplot core that it can't handle unicode strings, but plplot just anticipated that. I fixed the code in cvs and it works for me now in Kubuntu.
Should work for you as well. Thanks for the bug report. Werner Miguel de Val Borro wrote: > On Tue, Mar 20, 2007 at 08:02:39PM -0700, Alan W. Irwin wrote: > >> However, for both -DENABLE_DYNDRIVERS=OFF and ON you get segfaults with any >> example. Miguel, if you care to debug that further, valgrind should be a >> big help. I had a quick look with our simplest examples (x10c in the >> install tree), and it appears something is not defined (invalid read). I >> imagine there was some minor global change we made for all devices, and we >> forgot to make the change for pstex.c. >> > > Thanks for the last updates. I have tested some of the short C examples. > The segmentation fault is caused by some functions that write text and numeric > labels, like plptex, pllab and plenv. For example when the call to plptex is > removed in examples/c/x10c.c or x02c.c, the pstex driver creates a valid EPS > file. I have been looking at the recent changes to ps.c and psttf.cc but I > still don't understand why those functions cause the segmentation fault for > pstex. > > This is the output from valgrind when the plptex call is included in > x10c. > > ==9354== > ==9354== Invalid read of size 1 > ==9354== at 0x59438D2: parse_str (in > /home/miguel/lib/plplot5.7.2/driversd/pstex.so) > ==9354== by 0x5942B81: proc_str (in > /home/miguel/lib/plplot5.7.2/driversd/pstex.so) > ==9354== by 0x59426DE: plD_esc_pstex (in > /home/miguel/lib/plplot5.7.2/driversd/pstex.so) > ==9354== by 0x4B37B06: plP_esc (in /home/miguel/lib/libplplotd.so.9.2.1) > ==9354== by 0x4B38CA9: plP_text (in /home/miguel/lib/libplplotd.so.9.2.1) > ==9354== by 0x4B61325: c_plptex (in /home/miguel/lib/libplplotd.so.9.2.1) > ==9354== by 0x400A60: main (in > /home/miguel/share/plplot5.7.2/examples/c/x10c) > ==9354== Address 0x0 is not stack'd, malloc'd or (recently) free'd > ==9354== > ==9354== Process terminating with default action of signal 11 (SIGSEGV) > ==9354== Access not within mapped region at address 0x0 > ==9354== at 0x59438D2: parse_str (in > /home/miguel/lib/plplot5.7.2/driversd/pstex.so) > ==9354== by 0x5942B81: proc_str (in > /home/miguel/lib/plplot5.7.2/driversd/pstex.so) > ==9354== by 0x59426DE: plD_esc_pstex (in > /home/miguel/lib/plplot5.7.2/driversd/pstex.so) > ==9354== by 0x4B37B06: plP_esc (in /home/miguel/lib/libplplotd.so.9.2.1) > ==9354== by 0x4B38CA9: plP_text (in /home/miguel/lib/libplplotd.so.9.2.1) > ==9354== by 0x4B61325: c_plptex (in /home/miguel/lib/libplplotd.so.9.2.1) > ==9354== by 0x400A60: main (in > /home/miguel/share/plplot5.7.2/examples/c/x10c) > ==9354== > ==9354== ERROR SUMMARY: 5 errors from 5 contexts (suppressed: 8 from 1) > ==9354== malloc/free: in use at exit: 68,656 bytes in 173 blocks. > ==9354== malloc/free: 209 allocs, 36 frees, 86,803 bytes allocated. > ==9354== For counts of detected errors, rerun with: -v > ==9354== searching for pointers to 173 not-freed blocks. > ==9354== checked 268,888 bytes. > ==9354== > ==9354== LEAK SUMMARY: > ==9354== definitely lost: 0 bytes in 0 blocks. > ==9354== possibly lost: 0 bytes in 0 blocks. > ==9354== still reachable: 68,656 bytes in 173 blocks. > ==9354== suppressed: 0 bytes in 0 blocks. > Segmentation fault > > Miguel > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys-and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Plplot-devel mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/plplot-devel > ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys-and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ Plplot-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/plplot-devel
