| 
      
      
      From: Jim M. <ro...@vi...> - 2005-07-13 05:03:06
      
     | 
| I have attached a Cobol program that crashes the compiler with a segmentation fault. Here is the output ------------------------------------------ We are about to compile : jimtest /home/jim/bin/int: line 52: 2524 Segmentation fault htcobol -c -g -C -D -F -P -I $COBCPY -I $IO $PROG.cbl Woops! The compiler returned error : 139 [jim@byrlin3 work]$ ------------------------------------------------- I'm sorry I couldn't give you a shorter example, but the error disappears every time I delete a few lines of code. The error seems so flaky that I won't be surprised if you can't reproduce it. Our programing standards state that we shouldn't use "SECTIONS" in the PROCEDURE DIVISION, so I have little experience with the effects of SECTIONS. If I change the "MAINLINE SECTION" statement on line 212 to be just "MAINLINE" then the error goes away. Alternatively, If I move line 211 to line 213 the error also goes away. That is, when I move the statement PERFORM GET-DATABASE-TYPE. to be after the "MAINLINE SECTION" the error goes away. Alternatively, if I comment out line 254 - DISPLAY "SEARCH-ACCOUNT = " SEARCH-ACCOUNT. Then the error disappears. Alternatively, If I just delete apparently random lines of code, the error disappears. Jim |