Informix I4gl INPUT cause seg fault
Posted in 2007
Topics: Stored Procedures & SPL, Connectivity: ESQL/C, 4GL & Embedded SQL, Platform-Specific Issues
Greetings, Trying to complie Informix 4GL programs on AIX 5.3, IDS 11.10FC1, 4GL 7.32FC3, xlc 9. The programs compile fine, but I get a segmentation fault whenever the program trys an INPUT. The screen form displays just fine. The ring menus work. But program causes a Segmentation Fault whenever it reaches an INPUT statement. Even with a short formonly screen form, the program still segmentation faults. I feel that this is a library somewhere, but the only libraries used in the compile appear to be in /opt/IBM/informix directory. What is missing? Young Martin
On Nov 9, 7:46 pm, "Young Martin" <act_...@comcast.com> wrote: > Greetings, > > Trying to complie Informix 4GL programs on AIX 5.3, IDS 11.10FC1, 4GL > 7.32FC3, xlc 9. The programs compile fine, but I get a segmentation fault > whenever the program trys an INPUT. The screen form displays just fine. > The ring menus work. But program causes a Segmentation Fault whenever it > reaches an INPUT statement. Even with a short formonly screen form, the > program still segmentation faults. > > I feel that this is a library somewhere, but the only libraries used in > the compile appear to be in /opt/IBM/informix directory. > > What is missing? I wonder if this is the AIX / XLC equivalent of the 'gcc -fwritable- strings' problem? XLC v9 is (I think) fairly new, and I don't know which version of XLC was used to build the 7.32.FC3 version of I4GL. Check the I4GL release notes to see if you can discover the XLC version that was used. Or, you may be able to tell from the object code shipped with I4GL (eg the libraries). Also check the XLC release notes to see if you can find any information about string literals being non-writable by default (that's the problem in GCC, and it triggers seg faults there). See whether there's an option to make strings writable after all - if so, take a backup copy of the c4gl script, modify the original to include the special XLC option, and try again. If that fixes things, report the bug to IBM - the I4GL team, not the XLC team. -=JL=-
On 10 Nov, 17:14, Jonathan Leffler <jonathan.leff...@gmail.com> wrote: > On Nov 9, 7:46 pm, "Young Martin" <act_...@comcast.com> wrote: > > > Greetings, > > > Trying to complie Informix 4GL programs on AIX 5.3, IDS 11.10FC1, 4GL > > 7.32FC3, xlc 9. The programs compile fine, but I get a segmentation fault > > whenever the program trys an INPUT. The screen form displays just fine. > > The ring menus work. But program causes a Segmentation Fault whenever it > > reaches an INPUT statement. Even with a short formonly screen form, the > > program still segmentation faults. > > > I feel that this is a library somewhere, but the only libraries used in > > the compile appear to be in /opt/IBM/informix directory. > > > What is missing? > > I wonder if this is the AIX / XLC equivalent of the 'gcc -fwritable- > strings' problem? > > XLC v9 is (I think) fairly new, and I don't know which version of XLC > was used to build the 7.32.FC3 version of I4GL. Check the I4GL > release notes to see if you can discover the XLC version that was > used. Or, you may be able to tell from the object code shipped with > I4GL (eg the libraries). Also check the XLC release notes to see if > you can find any information about string literals being non-writable > by default (that's the problem in GCC, and it triggers seg faults > there). See whether there's an option to make strings writable after > all - if so, take a backup copy of the c4gl script, modify the > original to include the special XLC option, and try again. If that > fixes things, report the bug to IBM - the I4GL team, not the XLC team. > > -=JL=- What happened to fixing the gcc -fwritable-strings issue?
david@smooth1.co.uk wrote: > On 10 Nov, 17:14, Jonathan Leffler wrote: >> On Nov 9, 7:46 pm, "Young Martin" wrote: >>> Trying to compile Informix 4GL programs on AIX 5.3, IDS 11.10FC1, 4GL >>> 7.32FC3, xlc 9. The programs compile fine, but I get a segmentation fault >>> whenever the program trys an INPUT. [...] >> >> I wonder if this is the AIX / XLC equivalent of the 'gcc -fwritable- >> strings' problem? [...] > > What happened to fixing the gcc -fwritable-strings issue? I hope that it has been fixed - but I don't know whether it was fixed in the 7.32.xC3 release. Similarly, I was wondering out loud whether this was the problem with this version of XLC. Otherwise it is a bug of some sort in I4GL; actually, even if the problem is induced by XLC making strings non-writable, it is a bug in I4GL. Most probably it is a bug in I4GL, but I am assuming that the program worked before. (Actually, I'd like to think that I4GL wouldn't crash with a seg fault period.) -- Jonathan Leffler #include <disclaimer.h> Email: jleffler@earthlink.net, jleffler@us.ibm.com Guardian of DBD::Informix v2007.0914 -- http://dbi.perl.org/ publictimestamp.org/ptb/PTB-1754 tiger160 2007-11-10 18:00:08 DFCC53B753194D036BF8263DDFBC46B9F543BCCC
"Jonathan Leffler" <jonathan.leffler@gmail.com> wrote in message news:1194714888.790161.321060@d55g2000hsg.googlegroups.com... > On Nov 9, 7:46 pm, "Young Martin" <act_...@comcast.com> wrote: >> Greetings, >> >> Trying to complie Informix 4GL programs on AIX 5.3, IDS 11.10FC1, 4GL >> 7.32FC3, xlc 9. The programs compile fine, but I get a segmentation >> fault >> whenever the program trys an INPUT. The screen form displays just fine. >> The ring menus work. But program causes a Segmentation Fault whenever it >> reaches an INPUT statement. Even with a short formonly screen form, the >> program still segmentation faults. >> >> I feel that this is a library somewhere, but the only libraries used >> in >> the compile appear to be in /opt/IBM/informix directory. >> >> What is missing? > > I wonder if this is the AIX / XLC equivalent of the 'gcc -fwritable- > strings' problem? > > XLC v9 is (I think) fairly new, and I don't know which version of XLC > was used to build the 7.32.FC3 version of I4GL. Check the I4GL > release notes to see if you can discover the XLC version that was > used. Or, you may be able to tell from the object code shipped with > I4GL (eg the libraries). Also check the XLC release notes to see if > you can find any information about string literals being non-writable > by default (that's the problem in GCC, and it triggers seg faults > there). See whether there's an option to make strings writable after > all - if so, take a backup copy of the c4gl script, modify the > original to include the special XLC option, and try again. If that > fixes things, report the bug to IBM - the I4GL team, not the XLC team. > > -=JL=- > The writable-strings did not make a difference. A -f writable-strings with xlc was looking for a file. I tried -qwritable-strings, that compiled just fine, but still the segmentation fault at the first INPUT. Any other thoughts? Moving from Data General DG/UX 4.20MU07, IDS 7.31UC2, I4GL 7.20UD6. But, even simple form program bombs in same fashion. Thanks for any tips. Young Martin