r.in.srtm fails to validate zip files
|Reported by:||kyngchaos||Owned by:||hamish|
r.in.srtm uses "file -ib" on the zip file to check if it has the correct mime type. "-i" seems to be a very ambiguous way to specify the mime flag. The BSD version of file (at least on OSX) uses "-i" for the "do no classify" regular files option, and "-I" (uppercase) for the mime option, though has "-i" for mime listed as a legacy option. GNU file and old UNIX versions use "-i" for the mime option. SUS does not have mime as a minimum option to support.
It looks like all have the extended "--mime" flag. Attached is a patch to use that flag. There should probably be a way to handle the possibility of a system having a "file" command without any mime flag, but I don't know how to handle that, and it may not be critical.