apply new error handling to image.c
Merge branch 'master' of github.com:davidgao/libimgfeatures