]> git.ipfire.org Git - thirdparty/bacula.git/commit
Allow backtrace to work before the load of the config file
authorAlain Spineux <alain@baculasystems.com>
Thu, 16 Jul 2020 14:46:09 +0000 (16:46 +0200)
committerEric Bollengier <eric@baculasystems.com>
Thu, 24 Mar 2022 08:02:58 +0000 (09:02 +0100)
commit87dfca9748d9c044b76c96608292a512848950a1
treec6db015aacb49e4a1dd6df99ad9b2a9d178df796
parentab0349252cd73f9c705cdf8ecddc1cbe961492a5
Allow backtrace to work before the load of the config file

- working_directory is NULL until the config file has been loaded
- there was a bug in signal_handler(), working_directory (wd) was set to
  "buf" and we were doing a
  snprintf(buf, sizeof(buf), "%s/bacula.%s.traceback", wd, pid_buf);
  where wd and buf point to the same location, that was generating
  funny path like /bacula.7647.traceback/bacula.7647.traceback
- now we get something like /tmp/bacula.31150.traceback
- no need of any check in "btraceback"
bacula/src/lib/signal.c