Version 1 (modified by 14 years ago) ( diff ) | ,
---|
IsMounted
Check whether the specified file device is mounted
int IsMounted(const string& strMount); int IsMounted(const char* pszMount);
Parameters
- strMount - string variable containing name to check
- pszMount - character array containing name to check
Return Value
- Returns 1 if device is mounted, 0 if it is not mounted
Remarks
The function operates by reading /proc/mounts and checking for string match
Examples
string strMnt = "/mnt/fl1"; if(IsMounted(strMnt) == 0) { DisplayText(0, 0, "Flash is not mounted"); }
if(IsMounted("/mnt/fl1") == 0) { DisplayText(0, 0, "Flash is not mounted"); }
See Also
Note:
See TracWiki
for help on using the wiki.