Ignore:
Timestamp:
Feb 27, 2009, 5:08:07 AM (16 years ago)
Author:
bird
Message:

kash: malloc/free/friends gets a psh.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/kash/generated/nodes.c

    r1233 r2290  
    4949#include "machdep.h"
    5050#include "mystring.h"
     51#include "shinstance.h"
    5152
    5253
     
    99100
    100101union node *
    101 copyfunc(n)
     102copyfunc(psh, n)
     103    struct shinstance *psh;
    102104        union node *n;
    103105{
     
    107109        funcstringsize = 0;
    108110        calcsize(n);
    109         funcblock = ckmalloc(funcblocksize + funcstringsize);
     111        funcblock = ckmalloc(psh, funcblocksize + funcstringsize);
    110112        funcstring = (char *) funcblock + funcblocksize;
    111113        return copynode(n);
     
    340342
    341343void
    342 freefunc(n)
     344freefunc(psh, n)
     345    shinstance *psh;
    343346        union node *n;
    344347{
    345348        if (n)
    346                 ckfree(n);
    347 }
     349                ckfree(psh, n);
     350}
Note: See TracChangeset for help on using the changeset viewer.