How to get drive's volume name using C

Hi, i'm creating program, where i must display the information of inserted flash drive, so i need used space, full space, volume name, file system type to display.
To get used and full space i can use statfs() function, but what about others, how i can get volume name and file system type(or file system name)?
It sounds like you need mount information. Have a look in /etc/mtab.
Topic archived. No new replies allowed.