Save errno right after syscalls. am: c2e64a4d40 am: 01cd526dd6

Original change: https://googleplex-android-review.googlesource.com/c/platform/system/libvintf/+/12038021

Change-Id: Id9aaf15ac848df7c684cb567f99cabc41d2d835e