| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 80edda5 commit b599d81
1 file changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -322,8 +322,9 @@ static void MountFilesystems() { | |||
| 322 | 322 | } | |
| 323 | 323 | } | |
| 324 | 324 | ||
| 325 | - // Make sure that our working directory is a mount point. The easiest way to | ||
| 326 | - // do this is by bind-mounting it upon itself. | ||
| 325 | + // Make sure that the working directory is writable (unlike most of the rest | ||
| 326 | + // of the file system, which is read-only by default). The easiest way to do | ||
| 327 | + // this is by bind-mounting it upon itself. | ||
| 327 | 328 | PRINT_DEBUG("working dir: %s", opt.working_dir.c_str()); | |
| 328 | 329 | ||
| 329 | 330 | if (mount(opt.working_dir.c_str(), opt.working_dir.c_str(), nullptr, MS_BIND, | |
@@ -622,13 +623,15 @@ static void MountAllMounts() { | |||
| 622 | 623 | } | |
| 623 | 624 | } | |
| 624 | 625 | ||
| 625 | - // Make sure that our working directory is a mount point. The easiest way to | ||
| 626 | - // do this is by bind-mounting it upon itself. | ||
| 626 | + // Make sure that the working directory is writable (unlike most of the rest | ||
| 627 | + // of the file system, which is read-only by default). The easiest way to do | ||
| 628 | + // this is by bind-mounting it upon itself. | ||
| 627 | 629 | if (mount(opt.working_dir.c_str(), opt.working_dir.c_str(), nullptr, MS_BIND, | |
| 628 | 630 | nullptr) < 0) { | |
| 629 | 631 | DIE("mount(%s, %s, nullptr, MS_BIND, nullptr)", opt.working_dir.c_str(), | |
| 630 | 632 | opt.working_dir.c_str()); | |
| 631 | 633 | } | |
| 634 | + | ||
| 632 | 635 | for (int i = 0; i < (signed)opt.bind_mount_sources.size(); i++) { | |
| 633 | 636 | if (global_debug) { | |
| 634 | 637 | if (strcmp(opt.bind_mount_sources[i].c_str(), | |
| Back | FazBrowse Home | New Git URL |
0 commit comments