From 8665e5085e47e5a3223c4e7a0dc4b15d48f03d75 Mon Sep 17 00:00:00 2001
From: Christos Zoulas <christos@zoulas.com>
Date: Fri, 25 Mar 2005 18:03:18 +0000
Subject: [PATCH] Fix reversed logic in byte-swapping code.

---
 src/apprentice.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/apprentice.c b/src/apprentice.c
index 16c6e847..f93ed361 100644
--- a/src/apprentice.c
+++ b/src/apprentice.c
@@ -45,7 +45,7 @@
 #endif
 
 #ifndef	lint
-FILE_RCSID("@(#)$Id: apprentice.c,v 1.83 2005/03/06 05:58:22 christos Exp $")
+FILE_RCSID("@(#)$Id: apprentice.c,v 1.84 2005/03/25 18:03:18 christos Exp $")
 #endif	/* lint */
 
 #define	EATAB {while (isascii((unsigned char) *l) && \
@@ -1242,7 +1242,7 @@ bs1(struct magic *m)
 	m->cont_level = swap2(m->cont_level);
 	m->offset = swap4((uint32_t)m->offset);
 	m->in_offset = swap4((uint32_t)m->in_offset);
-	if (IS_STRING(m->type))
+	if (!IS_STRING(m->type))
 		m->value.l = swap4(m->value.l);
 	m->mask = swap4(m->mask);
 }
-- 
2.40.0