buffer-usage calculation.
- * $Id: env.c,v 1.3 2001/01/20 11:48:10 mdw Exp $
+ * $Id: env.c,v 1.4 2001/01/25 21:14:26 mdw Exp $
*
* Fiddling with environment variables
*
*
* Fiddling with environment variables
*
/*----- Revision history --------------------------------------------------*
*
* $Log: env.c,v $
/*----- Revision history --------------------------------------------------*
*
* $Log: env.c,v $
+ * Revision 1.4 2001/01/25 21:14:26 mdw
+ * Nowadays, @SYM_LEN@ doesn't include the terminating null, so revise the
+ * buffer-usage calculation.
+ *
* Revision 1.3 2001/01/20 11:48:10 mdw
* Use new @SYM_LEN@ macro for name lengths.
*
* Revision 1.3 2001/01/20 11:48:10 mdw
* Use new @SYM_LEN@ macro for name lengths.
*
for (sym_mkiter(&i, t); (v = sym_next(&i)) != 0; ) {
n++;
for (sym_mkiter(&i, t); (v = sym_next(&i)) != 0; ) {
n++;
- sz += SYM_LEN(v) + strlen(v->v) + 1;
+ sz += SYM_LEN(v) + strlen(v->v) + 2;
}
/* --- Allocate the big chunk of memory --- */
}
/* --- Allocate the big chunk of memory --- */