* disk.c (gp_port_library_list): ignore FUSE filesystem
entries. git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@9195 67ed7778-7388-44ab-90cf-0a291f65f57c
This commit is contained in:
@@ -1,3 +1,8 @@
|
||||
2006-09-19 Hubert Figuiere <hub@figuiere.net>
|
||||
|
||||
* disk.c (gp_port_library_list): ignore FUSE filesystem
|
||||
entries.
|
||||
|
||||
2005-06-15 Hubert Figuiere <hfiguiere@teaser.fr>
|
||||
|
||||
* disk.c (gp_port_library_list): unref the dbus connection
|
||||
|
||||
@@ -203,10 +203,12 @@ gp_port_library_list (GPPortInfoList *list)
|
||||
if (mnt) {
|
||||
while ((mntent = getmntent (mnt))) {
|
||||
/* detect floppies so we don't access them with the stat() below */
|
||||
if ( (NULL != strstr(mntent->mnt_fsname,"fd")) ||
|
||||
(NULL != strstr(mntent->mnt_fsname,"floppy"))
|
||||
)
|
||||
if ((NULL != strstr(mntent->mnt_fsname,"fd")) ||
|
||||
(NULL != strstr(mntent->mnt_fsname,"floppy")) ||
|
||||
(NULL != strstr(mntent->mnt_fsname, "fuse")))
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
snprintf (path, sizeof(path), "%s/DCIM", mntent->mnt_dir);
|
||||
if (-1 == stat(path, &stbuf)) {
|
||||
@@ -226,10 +228,12 @@ gp_port_library_list (GPPortInfoList *list)
|
||||
if (mnt) {
|
||||
while ((mntent = getmntent (mnt))) {
|
||||
/* detect floppies so we don't access them with the stat() below */
|
||||
if ( (NULL != strstr(mntent->mnt_fsname,"fd")) ||
|
||||
(NULL != strstr(mntent->mnt_fsname,"floppy"))
|
||||
)
|
||||
if ((NULL != strstr(mntent->mnt_fsname,"fd")) ||
|
||||
(NULL != strstr(mntent->mnt_fsname,"floppy")) ||
|
||||
(NULL != strstr(mntent->mnt_fsname, "fuse")))
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
snprintf (path, sizeof(path), "%s/DCIM", mntent->mnt_dir);
|
||||
if (-1 == stat(path, &stbuf)) {
|
||||
|
||||
Reference in New Issue
Block a user