mirror of
https://github.com/mhx/dwarfs.git
synced 2025-09-11 21:35:27 -04:00
Fix foreground check for fuse2
This commit is contained in:
parent
ce9216f581
commit
2e8a11ed28
@ -706,6 +706,8 @@ int run_dwarfs(int argc, char** argv) {
|
|||||||
if (fuse_opts.foreground) {
|
if (fuse_opts.foreground) {
|
||||||
folly::symbolizer::installFatalSignalHandler();
|
folly::symbolizer::installFatalSignalHandler();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool foreground = fuse_opts.foreground;
|
||||||
#else
|
#else
|
||||||
char* mountpoint = nullptr;
|
char* mountpoint = nullptr;
|
||||||
int mt, fg;
|
int mt, fg;
|
||||||
@ -717,6 +719,8 @@ int run_dwarfs(int argc, char** argv) {
|
|||||||
if (fg) {
|
if (fg) {
|
||||||
folly::symbolizer::installFatalSignalHandler();
|
folly::symbolizer::installFatalSignalHandler();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool foreground = fg;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
try {
|
try {
|
||||||
@ -727,7 +731,7 @@ int run_dwarfs(int argc, char** argv) {
|
|||||||
if (opts.debuglevel_str) {
|
if (opts.debuglevel_str) {
|
||||||
opts.debuglevel = logger::parse_level(opts.debuglevel_str);
|
opts.debuglevel = logger::parse_level(opts.debuglevel_str);
|
||||||
} else {
|
} else {
|
||||||
opts.debuglevel = fuse_opts.foreground ? logger::INFO : logger::WARN;
|
opts.debuglevel = foreground ? logger::INFO : logger::WARN;
|
||||||
}
|
}
|
||||||
|
|
||||||
userdata.lgr.set_threshold(opts.debuglevel);
|
userdata.lgr.set_threshold(opts.debuglevel);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user