Menu

#966 cobc crashes on illegal COBOL source code file

GC 3.x
closed
5 - default
2024-05-04
2024-05-03
No

Attached file will crash cobc version 3.2.0.

The source file is obviously illegal. This file came up when I manually translated a C source to COBOL source and just wanted to check whether my WORKING-STORAGE SECTION was OK so far.

The final message of the compiler is this

unknown (signal)

cobc: aborting compile of cobts2date.cob-crashCompiler at line 70 (PROGRAM-ID: Timestamp2date)
cobc: Please report this!
zsh: segmentation fault (core dumped) cobc cobts2date.cob-crashCompiler

1 Attachments

Related

Commit: [r5454]

Discussion

  • Vincent (Bryan) Coen

    It is bomming when reading non Cobol data such as your C code.

    Put that in a differenet code block that is called by the main program or in a different source file that is added to the cobc steering lines.

    i.e., cobc -x -FIXED cobol-test1.cbl c-test1.c

     
  • Simon Sobisch

    Simon Sobisch - 2024-05-04
    • labels: --> cobc, SIGSEGV
    • status: open --> closed
    • assigned_to: Simon Sobisch
    • Group: unclassified --> GC 3.x
     
  • Simon Sobisch

    Simon Sobisch - 2024-05-04

    Thank you for this report.
    This is a variant of [bugs:#933] (only triggering because of the parenthesis) and now fixed with [r5247].

     

    Related

    Bugs: #933
    Commit: [r5247]


Log in to post a comment.

MongoDB Logo MongoDB