clear the errno in each exported API when the call success
Signed-off-by: Chen Jingpiao <jchen@suse.com>