api to list Filesystem names (c++)
Hi,
How can I list Filesystem name if I have a path in c++. for example: if i fire following command on shell: df -k /someloc Filesystem 1K-blocks Used Available Use% Mounted on machine3:/someloc 18874 13808 15066 74% /some1/some2/someloc I just want output Filesystem name. I looked into df source code. I could not understand it much. I was wondering if there was a simple way to achieve the task. Thanks, Vipul |
You asked this already, and I told you the API: read /proc/self/mounts and find the longest matching prefix. The only thing I didn't do was to actually write the C++ for you.
|
All times are GMT -5. The time now is 07:53 PM. |