ensure zhash_foreach stops on non-zero return
Merge pull request #150 from avalanche123/5e5d99b607f0ca2ddebad6aa0569884eaf6bf0a1

fix zhash_foreach behavior