From b019ad1bc03a9418a7398d9eab1978f0b8059675 Mon Sep 17 00:00:00 2001 From: Marcel Moolenaar Date: Sun, 20 Oct 2002 23:39:43 +0000 Subject: [PATCH] In cb_dumphdr() we were calling buf_write() with di->priv as the pointer to a dumperinfo instead of di. A brainfart, surely. This bug went unnoticed for all this time because the pointer is only used by buf_write() when it can write a completely filled buffer to the dump device. This depends on the number of memory chunks that needs to be dumped. This has apparently been low enough that it has never happened up until this point. --- sys/ia64/ia64/dump_machdep.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/ia64/ia64/dump_machdep.c b/sys/ia64/ia64/dump_machdep.c index 2af310f8bad9..00994620240e 100644 --- a/sys/ia64/ia64/dump_machdep.c +++ b/sys/ia64/ia64/dump_machdep.c @@ -174,7 +174,7 @@ cb_dumphdr(EFI_MEMORY_DESCRIPTOR *mdp, int seqnr, void *arg) phdr.p_memsz = mdp->NumberOfPages << EFI_PAGE_SHIFT; phdr.p_align = EFI_PAGE_SIZE; - error = buf_write(di->priv, (char*)&phdr, sizeof(phdr)); + error = buf_write(di, (char*)&phdr, sizeof(phdr)); fileofs += phdr.p_filesz; return (error); }