rem: unsigned curmax = 0;
add: register unsigned curmax = 0;
context: static proc_t **procs_refresh (proc_t **table, int flags){#define PTRsz  sizeof(proc_t *)#define ENTsz  sizeof(proc_t)   static unsigned savmax = 0;          // first time, Bypass: (i)   proc_t *ptsk = (proc_t *)-1;         // first time, Force: (ii)   unsigned curmax = 0;                 // every time  (jeeze)   PROCTAB* PT;   prochlp(NULL);                       // prep for a new frame   if (Monpidsidx)      PT = openproc(flags | PROC_PID, Monpids);   else      PT = openproc(flags);   // i) Allocated Chunks:  *Existing* table;  refresh + reuse   while (curmax < savmax) {      if (table[curmax]->cmdline) {         free(*table[curmax]->cmdline);         table[curmax]->cmdline = NULL;      }      if (!(ptsk = readproc(PT, table[curmax]))) break;      prochlp(ptsk);                    // tally & complete this proc_t      ++curmax;   }   // ii) Unallocated Chunks:  *New* or *Existing* table;  extend + fill   while (ptsk) {      // realloc as we go, keeping 'table' ahead of 'currmax++'      table = alloc_r(table, (curmax + 1) * PTRsz);      // here, readproc will allocate the underlying proc_t stg      if ((ptsk = readproc(PT, NULL))) {         prochlp(ptsk);                 // tally & complete this proc_t         table[curmax++] = ptsk;      }   }   closeproc(PT);   // iii) Chunkless:  make 'eot' entry, after ensuring proc_t exists   if (curmax >= savmax) {      table = alloc_r(table, (curmax + 1) * PTRsz);      // here, we must allocate the underlying proc_t stg ourselves      table[curmax] = alloc_c(ENTsz);      savmax = curmax + 1;   }   // this frame's end, but not necessarily end of allocated space   table[curmax]->pid = -1;   return table;#undef PTRsz#undef ENTsz}