From 515008006b2f16f54c1d5d0a0b9e69b95ff69ef1 Mon Sep 17 00:00:00 2001 From: Jonathan Gray Date: Wed, 11 Nov 2009 16:21:52 +0000 Subject: fix a buffer overflow found by parfait ok millert@ --- usr.bin/file/apprentice.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'usr.bin') diff --git a/usr.bin/file/apprentice.c b/usr.bin/file/apprentice.c index 1e825b6c2a5..42d8ca2514d 100644 --- a/usr.bin/file/apprentice.c +++ b/usr.bin/file/apprentice.c @@ -1,4 +1,4 @@ -/* $OpenBSD: apprentice.c,v 1.28 2009/10/27 23:59:37 deraadt Exp $ */ +/* $OpenBSD: apprentice.c,v 1.29 2009/11/11 16:21:51 jsg Exp $ */ /* * Copyright (c) Ian F. Darwin 1986-1995. * Software written by Ian F. Darwin and others; @@ -2084,7 +2084,7 @@ swap4(uint32_t sv) private uint64_t swap8(uint64_t sv) { - uint32_t rv; + uint64_t rv; uint8_t *s = (uint8_t *)(void *)&sv; uint8_t *d = (uint8_t *)(void *)&rv; #if 0 -- cgit v1.2.3