Skip to content

Unreachable code for signal unblock in create function for threads #1

@marirsg2

Description

@marirsg2

in gtthread_sched.c , function gtthread_create, line 190
the code sigprocmask(SIG_UNBLOCK, &sigmaskset, NULL);
is unreachable and the function will always return before it.

fix: move the unblock code into the end of the preceeding if statement, AND the else statement.
This is one of the joys of having mid function return statements :-)

otherwise, I enjoyed reading your code very much. It helped a lot. Go Federer !

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions