summaryrefslogtreecommitdiff
path: root/UCore.pas
diff options
context:
space:
mode:
authorTomas Bzatek <tbzatek@vmrawhide.w2k3dom>2008-10-06 12:36:24 +0200
committerTomas Bzatek <tbzatek@vmrawhide.w2k3dom>2008-10-06 12:36:24 +0200
commita6cc39e45a4464a037f82743e5b6a74a0df64036 (patch)
tree06d8cf093eb88beac2153a385332f5775574a036 /UCore.pas
parentace02c1d8fb3ae997efbac0a12d3bd0533bd93d9 (diff)
downloadtuxcmd-a6cc39e45a4464a037f82743e5b6a74a0df64036.tar.xz
Skip '0' and NULL mount points
Diffstat (limited to 'UCore.pas')
-rw-r--r--UCore.pas7
1 files changed, 4 insertions, 3 deletions
diff --git a/UCore.pas b/UCore.pas
index 374045f..b2ac837 100644
--- a/UCore.pas
+++ b/UCore.pas
@@ -2386,11 +2386,12 @@ begin
// Get mount name
mntent := getmntent(fd);
while mntent <> nil do begin
- DebugMsg(['FillDefaultFstabMounterItems: found "', mntent^.mnt_dir, '" --> "', mntent^.mnt_fsname, '", fstype ', mntent^.mnt_type]);
- if (mntent^.mnt_dir <> '/') and (mntent^.mnt_dir <> '/boot') and (Pos('/proc', mntent^.mnt_dir) <> 1) and
+ DebugMsg(['FillDefaultFstabMounterItems: found "', mntent^.mnt_dir, '" --> "', mntent^.mnt_fsname, '", fstype "', mntent^.mnt_type, '"']);
+ if (mntent^.mnt_dir <> nil) and (mntent^.mnt_type <> nil) and (strlen(mntent^.mnt_dir) > 0) and (strlen(mntent^.mnt_type) > 0) and
+ (mntent^.mnt_dir <> '/') and (mntent^.mnt_dir <> '/boot') and (Pos('/proc', mntent^.mnt_dir) <> 1) and
(Pos('/dev', mntent^.mnt_dir) <> 1) and (Pos('/sys', mntent^.mnt_dir) <> 1) and (mntent^.mnt_dir <> 'swap') and
(mntent^.mnt_type <> 'swap') and (mntent^.mnt_type <> 'rpc_pipefs') and (mntent^.mnt_type <> 'none') and
- (mntent^.mnt_dir <> 'none') and (mntent^.mnt_dir <> '') then
+ (mntent^.mnt_dir <> 'none') then
begin
MounterItem := TMounterItem.Create;
MounterItem.DisplayText := '';