diff options
| author | Reuben Thomas <rrt@sc3d.org> | 2011-01-07 23:22:28 +0000 |
|---|---|---|
| committer | Reuben Thomas <rrt@sc3d.org> | 2011-01-07 23:22:28 +0000 |
| commit | 07566bb419a3cf2992a7bcb888e896123078b8d9 (patch) | |
| tree | e2a563404404bd2da770c03cce58f8b871a4b646 | |
| parent | adaeaa1baec6e6d63bb1059022e5df2c51b14a08 (diff) | |
| download | file-git-07566bb419a3cf2992a7bcb888e896123078b8d9.tar.gz | |
Remove some #if 0âd code that had no reason to be left in.
| -rw-r--r-- | src/softmagic.c | 16 |
1 files changed, 2 insertions, 14 deletions
diff --git a/src/softmagic.c b/src/softmagic.c index 0524bdd8..99a7b524 100644 --- a/src/softmagic.c +++ b/src/softmagic.c @@ -32,7 +32,7 @@ #include "file.h" #ifndef lint -FILE_RCSID("@(#)$File: softmagic.c,v 1.143 2010/12/22 18:14:06 christos Exp $") +FILE_RCSID("@(#)$File: softmagic.c,v 1.144 2011/01/07 23:22:28 rrt Exp $") #endif /* lint */ #include "magic.h" @@ -144,7 +144,7 @@ match(struct magic_set *ms, struct magic *magic, uint32_t nmagic, default: if (m->type == FILE_INDIRECT) returnval = 1; - + switch (magiccheck(ms, m)) { case -1: return -1; @@ -790,12 +790,6 @@ mconvert(struct magic_set *ms, struct magic *m) case FILE_LESTRING16: { /* Null terminate and eat *trailing* return */ p->s[sizeof(p->s) - 1] = '\0'; -#if 0 - /* Why? breaks magic numbers that end with \xa */ - len = strlen(p->s); - if (len-- && p->s[len] == '\n') - p->s[len] = '\0'; -#endif return 1; } case FILE_PSTRING: { @@ -806,12 +800,6 @@ mconvert(struct magic_set *ms, struct magic *m) while (len--) *ptr1++ = *ptr2++; *ptr1 = '\0'; -#if 0 - /* Why? breaks magic numbers that end with \xa */ - len = strlen(p->s); - if (len-- && p->s[len] == '\n') - p->s[len] = '\0'; -#endif return 1; } case FILE_BESHORT: |
