]> git.ipfire.org Git - thirdparty/bacula.git/commit
use a UNIX file descriptor instead of FILE* for the trace file
authorAlain Spineux <alain@baculasystems.com>
Wed, 31 Aug 2022 14:23:54 +0000 (16:23 +0200)
committerEric Bollengier <eric@baculasystems.com>
Thu, 14 Sep 2023 11:56:59 +0000 (13:56 +0200)
commit88b290c4be7a05771b1b7fea655efab7aa0f337a
tree99a2a8274d2717f1c2a450a0d1058f55994e622f
parentb2437354545c1169a6de948ac0374b69f41a4d11
use a UNIX file descriptor instead of FILE* for the trace file

- avoid the double buffering that can be responsible for undesirable
  mix of debug message
- there is no justification for the use of a FILE*
  - every fputs() is followed by a fflush()
- Note from "man 2 open" concurrent write() to NFS using O_APPEND may lead to
  lead to corrupted files
bacula/src/lib/message.c
bacula/src/lib/message.h