Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/posix/signal.c

    rffff746 r4cf8ca6  
    6666
    6767/**
    68  * Default signal handler. Executes the default action for each signal,
    69  * as reasonable within HelenOS.
    70  *
    71  * @param signo Signal number.
     68 *
     69 * @param signo
    7270 */
    7371void __posix_default_signal_handler(int signo)
     
    7775                abort();
    7876        case SIGQUIT:
    79                 fprintf(stderr, "Quit signal raised. Exiting.\n");
     77                fprintf(stderr, "Quit signal raised. Exiting.");
    8078                exit(EXIT_FAILURE);
    8179        case SIGINT:
    82                 fprintf(stderr, "Interrupt signal caught. Exiting.\n");
     80                fprintf(stderr, "Interrupt signal caught. Exiting.");
    8381                exit(EXIT_FAILURE);
    8482        case SIGTERM:
    85                 fprintf(stderr, "Termination signal caught. Exiting.\n");
     83                fprintf(stderr, "Termination signal caught. Exiting.");
    8684                exit(EXIT_FAILURE);
    8785        case SIGSTOP:
    88                 fprintf(stderr, "Stop signal caught, but unsupported. Ignoring.\n");
     86                fprintf(stderr, "Stop signal caught, but unsupported. Ignoring.");
    8987                break;
    9088        case SIGKILL:
     
    252250                    " or fully unsupported signal. This handler may only be"
    253251                    " invoked by the raise() function, which may not be what"
    254                     " the application developer intended");
     252                    " the application developer intended.\nSignal name");
    255253        }
    256254
     
    360358        }
    361359
    362         if (signo > _TOP_SIGNAL) {
    363                 errno = EINVAL;
    364                 return -1;
    365         }
    366 
    367360        if (pid == (posix_pid_t) task_get_id()) {
    368361                return posix_raise(signo);
     362        }
     363
     364        if (pid > _TOP_SIGNAL) {
     365                errno = EINVAL;
     366                return -1;
    369367        }
    370368
Note: See TracChangeset for help on using the changeset viewer.