428 |
|
|
429 |
FILE *mntfd; |
FILE *mntfd; |
430 |
|
|
431 |
#ifdef HAVE_MTAB |
#ifdef HAVE_MTAB |
432 |
|
|
433 |
struct mntent *mnt; |
struct mntent *mnt; |
434 |
|
|
447 |
|
|
448 |
endmntent(mntfd); |
endmntent(mntfd); |
449 |
|
|
450 |
#elif defined HAVE_MNTTAB |
#elif defined HAVE_MNTTAB |
451 |
|
|
452 |
struct mnttab mnt; |
struct mnttab mnt; |
453 |
|
|
466 |
|
|
467 |
fclose(mntfd); |
fclose(mntfd); |
468 |
|
|
469 |
#else |
#else |
470 |
|
|
471 |
log("%s: Unsupported mounted filesystem information method", prog); |
log("%s: Unsupported mounted filesystem information method", prog); |
472 |
return NULL; |
return NULL; |
473 |
|
|
474 |
#endif |
#endif |
475 |
|
|
476 |
return path; |
return path; |
477 |
|
|
492 |
*/ |
*/ |
493 |
int get_fsusage(char *object, DeviceInfo_T buf) { |
int get_fsusage(char *object, DeviceInfo_T buf) { |
494 |
|
|
495 |
#if (defined HAVE_STATFS) || (defined HAVE_STATVFS) |
#if (defined HAVE_STATFS) || (defined HAVE_STATVFS) |
496 |
|
|
497 |
struct statfs usage; |
struct statfs usage; |
498 |
|
|
499 |
#else |
#else |
500 |
|
|
501 |
log("%s: Unsupported filesystem informations gathering method\n", prog); |
log("%s: Unsupported filesystem informations gathering method\n", prog); |
502 |
|
|
503 |
return FALSE; |
return FALSE; |
504 |
|
|
505 |
#endif |
#endif |
506 |
|
|
507 |
char path[STRLEN]; |
char path[STRLEN]; |
508 |
|
|