Changeset 1198 for trunk/src/kash/trap.c


Ignore:
Timestamp:
Oct 6, 2007, 11:19:19 PM (18 years ago)
Author:
bird
Message:

moving globals into shinstance...

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/kash/trap.c

    r809 r1198  
    102102
    103103        if (is_number(p))
    104                 return number(p);
     104                return number(psh, p);
    105105
    106106        if (strcasecmp(p, "exit") == 0 )
     
    190190        while (*ap) {
    191191                if (is_number(*ap))
    192                         signo = number(*ap);
     192                        signo = number(psh, *ap);
    193193                else
    194194                        signo = signame_to_signum(*ap);
     
    264264                switch (signo) {
    265265                case SIGINT:
    266                         if (iflag || minusc || sflag == 0)
     266                        if (iflag(psh) || minusc || sflag(psh) == 0)
    267267                                action = S_CATCH;
    268268                        break;
    269269                case SIGQUIT:
    270270#ifdef DEBUG
    271                         if (debug)
     271                        if (debug(psh))
    272272                                break;
    273273#endif
    274274                        /* FALLTHROUGH */
    275275                case SIGTERM:
    276                         if (iflag)
     276                        if (iflag(psh))
    277277                                action = S_IGN;
    278278                        break;
     
    280280                case SIGTSTP:
    281281                case SIGTTOU:
    282                         if (mflag)
     282                        if (mflag(psh))
    283283                                action = S_IGN;
    284284                        break;
     
    302302                }
    303303                if (sigact == SIG_IGN) {
    304                         if (mflag && (signo == SIGTSTP ||
     304                        if (mflag(psh) && (signo == SIGTSTP ||
    305305                             signo == SIGTTIN || signo == SIGTTOU)) {
    306306                                tsig = S_IGN;   /* don't hard ignore these */
Note: See TracChangeset for help on using the changeset viewer.