summaryrefslogtreecommitdiffstats
path: root/sbin/savecore
diff options
context:
space:
mode:
authorgallatin <gallatin@FreeBSD.org>2001-09-13 21:19:13 +0000
committergallatin <gallatin@FreeBSD.org>2001-09-13 21:19:13 +0000
commitaa094c1b930f7056fe73997f6128a518ebc525ed (patch)
treeea2cf20b245c4b8517285963500a6a609135aec9 /sbin/savecore
parent30b1089d33d73e2f1ba32d9f419400d07ebf4b27 (diff)
downloadFreeBSD-src-aa094c1b930f7056fe73997f6128a518ebc525ed.zip
FreeBSD-src-aa094c1b930f7056fe73997f6128a518ebc525ed.tar.gz
fix savecore so that it works on the alpha after the size change
of dumpmag from an int to a u_long in rev 1.41 -- without this change, savecore will always fail like this: #savecore -v /var/crash dumplo = 874356736 (1707728 * 512) savecore: magic number mismatch (8fca0101 != 8fca0101) savecore: no core dump
Diffstat (limited to 'sbin/savecore')
-rw-r--r--sbin/savecore/savecore.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sbin/savecore/savecore.c b/sbin/savecore/savecore.c
index 966d18a..5c6bdb5 100644
--- a/sbin/savecore/savecore.c
+++ b/sbin/savecore/savecore.c
@@ -328,7 +328,7 @@ check_kmem()
void
clear_dump()
{
- int newdumpmag;
+ u_long newdumpmag;
newdumpmag = 0;
DumpWrite(dumpfd, &newdumpmag, sizeof(newdumpmag),
@@ -343,7 +343,7 @@ clear_dump()
int
dump_exists()
{
- int newdumpmag;
+ u_long newdumpmag;
DumpRead(dumpfd, &newdumpmag, sizeof(newdumpmag),
(off_t)(dumplo + ok(dump_nl[X_DUMPMAG].n_value)), L_SET);
OpenPOWER on IntegriCloud