Репозитории ALT
S: | 2.1.5-alt4 |
5.1: | 2.1.5-alt3 |
4.1: | 2.1.5-alt3 |
4.0: | 2.1.5-alt3 |
3.0: | 2.1.0-alt1 |
Другие репозитории
Upstream: | 2.1.5 |
Группа :: Система/Ядро и оборудование
Пакет: eject
Главная Изменения Спек Патчи Sources Загрузить Gear Bugs and FR Repocop
Патч: eject-2.1.5-alt-supersubmount.patch
Скачать
Скачать
--- eject/eject.c
+++ eject/eject.c
@@ -869,6 +869,15 @@ static int MountedDevice(const char *nam
for (mntentry = getmntent(fp); mntentry; mntentry = getmntent(fp)) {
int mtabmaj, mtabmin;
+ if (strcmp(mntentry->mnt_type,"supermount") == 0) {
+ m_option = 1;
+ }
+ if (strcmp(mntentry->mnt_type,"subfs") == 0) {
+ m_option = 1;
+ }
+ if (strcmp(mntentry->mnt_fsname, "none") == 0) {
+ continue;
+ }
GetMajorMinor(mntentry->mnt_fsname, &mtabmaj, &mtabmin);
if (((strcmp(mntentry->mnt_fsname, name) == 0) || (strcmp(mntentry->mnt_dir, name) == 0)) ||
((maj != -1) && (maj == mtabmaj) && (min == mtabmin))) {
@@ -911,6 +920,9 @@ static int MountableDevice(const char *n
for (mntentry = getmntent(fp); mntentry; mntentry = getmntent(fp)) {
if (strcmp(mntentry->mnt_fsname,"#") && strcmp(mntentry->mnt_dir, name) == 0) {
+ if (strcmp(mntentry->mnt_fsname, "none") == 0) {
+ continue;
+ }
endmntent(fp);
*deviceName = strdup(mntentry->mnt_fsname);
*mountName = strdup(mntentry->mnt_dir);
@@ -947,8 +959,17 @@ static void UnmountDevices(const char *p
for (mntentry = getmntent(fp); mntentry; mntentry = getmntent(fp))
{
+ if (strcmp(mntentry->mnt_type,"supermount") == 0) {
+ m_option = 1;
+ }
+ if (strcmp(mntentry->mnt_type,"subfs") == 0) {
+ m_option = 1;
+ }
+ if (strcmp(mntentry->mnt_fsname, "none") == 0) {
+ continue;
+ }
status = regexec(&preg, mntentry->mnt_fsname, 0, 0, 0);
- if (status == 0)
+ if (status == 0 && m_option != 1)
{
if (v_option)
printf(_("%s: unmounting `%s'\n"), programName, mntentry->mnt_fsname);