diff options
author | taw27 <taw27@bf6ca9ba-c028-0410-8290-897cf20841d1> | 2007-04-01 17:42:13 +0000 |
---|---|---|
committer | taw27 <taw27@bf6ca9ba-c028-0410-8290-897cf20841d1> | 2007-04-01 17:42:13 +0000 |
commit | 63affa283744195cd6bd3de6b9c45b2362b8b1b9 (patch) | |
tree | 07485f750f11a1d03db81b43b265fd596a376046 /src/mrc.c | |
parent | 3a6347591e01e019d25df3faf274152cb97edb1d (diff) |
(Slightly) More advanced detection of input file type
git-svn-id: svn://cook.msm.cam.ac.uk:745/diff-tomo/dtr@21 bf6ca9ba-c028-0410-8290-897cf20841d1
Diffstat (limited to 'src/mrc.c')
-rw-r--r-- | src/mrc.c | 12 |
1 files changed, 12 insertions, 0 deletions
@@ -16,6 +16,7 @@ #include <stdlib.h> #include <stdio.h> #include <stdint.h> +#include <string.h> #include "mrc.h" #include "control.h" @@ -139,3 +140,14 @@ int mrc_read(ControlContext *ctx) { return 0; } + +unsigned int mrc_is_mrcfile(const char *filename) { + + if ( strcmp(filename+(strlen(filename)-4), ".mrc") == 0 ) { + return 1; + } + + return 0; + +} + |