Fixed wrong deinit on error path.
Fixed wrong deinit on error path.

jjz/libetpan,tipbit/libetpan,tipbit/libetpan,tipbit/libetpan,jjz/libetpan,disaykin/libetpan,jjz/libetpan,disaykin/libetpan,disaykin/libetpan