Merge "fs_mgr: fix errno setted by mount_with_alternatives"
diff --git a/fs_mgr/fs_mgr.cpp b/fs_mgr/fs_mgr.cpp
index d0e4682..6c84d73 100644
--- a/fs_mgr/fs_mgr.cpp
+++ b/fs_mgr/fs_mgr.cpp
@@ -563,8 +563,10 @@
                 }
             } else {
                 fs_stat |= FS_STAT_FULL_MOUNT_FAILED;
-                /* back up errno for crypto decisions */
-                mount_errno = errno;
+                /* back up the first errno for crypto decisions */
+                if (mount_errno == 0) {
+                    mount_errno = errno;
+                }
             }
             log_fs_stat(fstab->recs[i].blk_device, fs_stat);
     }