Re: cmd: Avoid rereading batch file for every call/goto executed (try 2)

2011-09-05 Thread Frédéric Delanoy
On Mon, Sep 5, 2011 at 14:35, Henri Verbeet wrote: > 2011/9/5 Frédéric Delanoy : >> +        keys = HeapAlloc(GetProcessHeap(), 0, capacity * sizeof(WCHAR*)); >> +        vals = HeapAlloc(GetProcessHeap(), 0, capacity * >> sizeof(LARGE_INTEGER)); > ... >> +                    keys = HeapReAlloc(G

Re: cmd: Avoid rereading batch file for every call/goto executed (try 2)

2011-09-05 Thread Henri Verbeet
2011/9/5 Frédéric Delanoy : > +        keys = HeapAlloc(GetProcessHeap(), 0, capacity * sizeof(WCHAR*)); > +        vals = HeapAlloc(GetProcessHeap(), 0, capacity * > sizeof(LARGE_INTEGER)); ... > +                    keys = HeapReAlloc(GetProcessHeap(), 0, keys, > +                              

Re: cmd: Avoid rereading batch file for every call/goto executed (try 2)

2011-09-05 Thread Frédéric Delanoy
On Mon, Sep 5, 2011 at 06:47, Octavian Voicu wrote: > 2011/9/5 Frédéric Delanoy : >> +        static WCHAR string[MAX_PATH]; > > Why make this static? It's only a temporary buffer and it's only used > once, when building the cache. Yeah true. Bad copy-paste from old WCMD_goto, although making it

Re: cmd: Avoid rereading batch file for every call/goto executed (try 2)

2011-09-04 Thread Octavian Voicu
2011/9/5 Frédéric Delanoy : > +        static WCHAR string[MAX_PATH]; Why make this static? It's only a temporary buffer and it's only used once, when building the cache. Octavian