Skip to content

SIGINT handler not restored after calling ParseAST() #4337

@llvmbot

Description

@llvmbot
Bugzilla Link 3965
Resolution FIXED
Resolved on Mar 12, 2010 00:56
Version unspecified
OS All
Attachments exit(1); -> raise(Sig); patch
Reporter LLVM Bugzilla Contributor

Extended Description

This is similar to http://llvm.org/bugs/show_bug.cgi?id=3848

However, the problem is that even when there is no custom interrupt function set, the signal handler does an exit(1); when receiving a SIGINT, rather than calling the default handler.

It seems the custom signal handler persists even after clang returns from ParseAST().

The attached patch changes the behaviour of receiving a SIGINT to run the previous handler rather than calling exit(1).

A better solution may be to actually unregister the damn handler before clang exits from ParseAST() - but I'm not sure where this code would have to go.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugzillaIssues migrated from bugzillaclang:frontendLanguage frontend issues, e.g. anything involving "Sema"

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions