Ignore:
Timestamp:
Sep 17, 2020, 11:52:16 PM (5 years ago)
Author:
bird
Message:

kash: Use kHlpAssert instead of assert.h (debugger stops on the assertion rather than at exit process code).

File:
1 edited

Legend:

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

    r3473 r3477  
    4343#include <sys/types.h>
    4444#include <limits.h>         /* PIPE_BUF */
    45 #include <assert.h>
    4645#include <string.h>
    4746#include <errno.h>
     
    158157        idxexpfname = 0;
    159158        for (n = redir, idxexpfname = 0 ; n ; n = n->nfile.next, idxexpfname++) {
    160                 assert(idxexpfname < psh->expfnames->count);
     159                kHlpAssert(idxexpfname < psh->expfnames->count);
    161160                fd = n->nfile.fd;
    162161                try = 0;
     
    196195                        openredirect(psh, n, memory, flags, psh->expfnames->names[idxexpfname]);
    197196        }
    198         assert(!redir || idxexpfname == psh->expfnames->count);
     197        kHlpAssert(!redir || idxexpfname == psh->expfnames->count);
    199198        if (memory[1])
    200199                psh->out1 = &psh->memout;
Note: See TracChangeset for help on using the changeset viewer.