mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-09-01 18:01:13 +02:00
gui/nfs: add default for local dir, autocreate local dir
This commit is contained in:
@@ -35,6 +35,7 @@
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include <system/fsmounter.h>
|
#include <system/fsmounter.h>
|
||||||
|
#include <system/helpers.h>
|
||||||
#include <cstdlib>
|
#include <cstdlib>
|
||||||
#include <fstream>
|
#include <fstream>
|
||||||
#include <limits>
|
#include <limits>
|
||||||
@@ -201,6 +202,9 @@ CFSMounter::MountRes CFSMounter::mount(const std::string &ip, const std::string
|
|||||||
}
|
}
|
||||||
|
|
||||||
printf("[CFSMounter] Mount(%d) %s:%s -> %s\n", (int) fstype, ip.c_str(), dir.c_str(), local_dir.c_str());
|
printf("[CFSMounter] Mount(%d) %s:%s -> %s\n", (int) fstype, ip.c_str(), dir.c_str(), local_dir.c_str());
|
||||||
|
|
||||||
|
CFileHelpers fh;
|
||||||
|
fh.createDir(local_dir.c_str(), 0755);
|
||||||
|
|
||||||
if (isMounted(local_dir))
|
if (isMounted(local_dir))
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user