Date: Thu, 13 Nov 2003 14:20:59 -0600 From: Jeremy Messenger <mezz7@cox.net> To: Franz Klammer <klammer@webonaut.com> Cc: gnome@freebsd.org Subject: Re: libdesklets/Disk.py - mounting point dedection Message-ID: <opryles9at8ckrg5@smtp.central.cox.net> In-Reply-To: <3FB3D404.2060303@webonaut.com>
index | next in thread | previous in thread | raw e-mail
On Thu, 13 Nov 2003 19:57:08 +0100, Franz Klammer <klammer@webonaut.com>
wrote:
> the mountingpoint dedectin (at least on -current) didn't work
> correctly. i geot this output if with "print data":
>
> ((4294967295L, '/dev/ad0s1a', '/', '?'), (4294967295L, 'devfs', '/dev',
> '?'), (4 294967295L, '/dev/ad0s1e', '/usr', '?'), (4294967295L,
> '/dev/ad0s1d', '/var', '? '), (4294967295L, 'linprocfs',
> '/usr/compat/linux/proc', '?'), (4294967295L, 'pr ocfs', '/proc', '?'),
> (4294967295L, '/dev/acd0', '/cdrom', '?'))
>
> as you can see the filesystem will not be dedected: '?'.
> i've changed the code that it works like in the network-interface
> dedection. Sysinfo now shows up the devices. here my code:
Ummm... Well, doesn't it means, we should fix the libgtop instead fix the
libdesklets/Disk.py? They removed the Linux'ish and use libgtop to allow
the things work on the platforums. Make sense?
Cheers,
Mezz
> def __poll_partitions(self):
>
> fd = os.popen("mount -p")
> data = fd.readlines()
> fd.close()
>
> partitions = []
> for lines in data:
> fields = lines.strip().replace("\t", " ").split()
> if (fields[2] in ("ext2", "ext3", "msdos", "vfat", "ntfs",
> "hpfs"
> "jfs", "reiserfs", "xfs", "qnx4", "adfs",
> "ffs",
> "hfs", "befs", "bfs", "efs", "iso9660",
> "minix",
> "sysv", "coda", "nfs", "udf", "ufs",
> "xiafs")):
> partitions.append((fields[0], fields[1]))
> #end for
>
> return partitions
>
> the only thing that doesn't work in SysInfo now is to switch
> from RAM to SWAP ... let's see ... :-)
>
> franz.
--
bsdforums.org 's moderator, mezz.
home |
help
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?opryles9at8ckrg5>
