From e08bedf9bf552826a2e326009ce162e24417de22 Mon Sep 17 00:00:00 2001 From: Greg Lehey Date: Tue, 29 Feb 2000 06:13:24 +0000 Subject: [PATCH] Malloc: Save the caller's file name in the correct entry. --- sys/dev/vinum/vinummemory.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/dev/vinum/vinummemory.c b/sys/dev/vinum/vinummemory.c index 020df4e9ab6..59b5d5a94fe 100644 --- a/sys/dev/vinum/vinummemory.c +++ b/sys/dev/vinum/vinummemory.c @@ -168,8 +168,8 @@ MMalloc(int size, char *file, int line) malloced[i].size = size; malloced[i].line = line; malloced[i].address = result; - bcopy(f, malloced[lastfree].file, min(strlen(f), MCFILENAMELEN - 1)); - malloced[lastfree].file[MCFILENAMELEN - 1] = '\0'; + bcopy(f, malloced[i].file, min(strlen(f), MCFILENAMELEN - 1)); + malloced[i].file[MCFILENAMELEN - 1] = '\0'; } if (malloccount > highwater) highwater = malloccount;