Merge "[Upstream] Fix return value in error path." into tizen