From 9423a6885330f2fea8c89a95ac66c6af3eac824f Mon Sep 17 00:00:00 2001 From: "[CST] Focus" Date: Tue, 10 Feb 2015 15:04:52 +0300 Subject: [PATCH] Revert "hdd_menu: do not handle the rootfs or fs without kernel support" This reverts commit 1a4ac8b2818922df5d6fbbf7cd4f967c3a23824c. Origin commit data ------------------ Branch: ni/coolstream Commit: https://github.com/neutrino-images/ni-neutrino/commit/342180a28be4abc1189445177aaeca10a7962594 Author: [CST] Focus Date: 2015-02-10 (Tue, 10 Feb 2015) ------------------ This commit was generated by Migit --- src/gui/hdd_menu.cpp | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/src/gui/hdd_menu.cpp b/src/gui/hdd_menu.cpp index 2b6a21c83..dec5f7428 100644 --- a/src/gui/hdd_menu.cpp +++ b/src/gui/hdd_menu.cpp @@ -778,11 +778,9 @@ _show_menu: } if (!hdd_list.empty()) { - struct stat rec_st, root_st, dev_st; + struct stat rec_st; memset(&rec_st, 0, sizeof(rec_st)); - memset(&root_st, 0, sizeof(root_st)); stat(g_settings.network_nfs_recordingdir.c_str(), &rec_st); - stat("/", &root_st); sort(hdd_list.begin(), hdd_list.end(), cmp_hdd_by_name()); mount = g_Locale->getText(LOCALE_HDD_MOUNT); @@ -798,13 +796,6 @@ _show_menu: } std::string key = "m" + it->devname; bool enabled = !rec_icon || !CNeutrinoApp::getInstance()->recordingstatus; - /* do not allow to unmount the rootfs, and skip filesystems without kernel support */ - memset(&dev_st, 0, sizeof(dev_st)); - if (stat(("/dev/" + it->devname).c_str(), &dev_st) != -1 - && dev_st.st_rdev == root_st.st_dev) - enabled = false; - else if (kernel_fs_list.find(it->fmt) == kernel_fs_list.end()) - enabled = false; it->cmf = new CMenuForwarder(it->desc, enabled, it->mounted ? umount : mount , this, key.c_str(), CRCInput::convertDigitToKey(shortcut++), NULL, rec_icon); hddmenu->addItem(it->cmf);