]> git.ipfire.org Git - thirdparty/bacula.git/commit
Fix org#2567 Device don't always get the right "capabilities"
authorAlain Spineux <alain@baculasystems.com>
Tue, 1 Dec 2020 12:59:21 +0000 (13:59 +0100)
committerEric Bollengier <eric@baculasystems.com>
Thu, 24 Mar 2022 08:02:57 +0000 (09:02 +0100)
commit07cfd6bc5814d2b25aa290521ee00e3ab910ae16
tree8dc7eca2602609e621c445b5e41f65b90cd383aa
parent8a0d39fede66816a6bafba4461c27df6f643fc35
Fix org#2567 Device don't always get the right "capabilities"

- "capabilities" was sometime adjusted in the constructor or in the factory
  function, but device_generic_init() that is called later by init_dev()
  initialize most of the device fields including "capabilities"
- move the tweak of the "capabilities" in device_specific_init()
  that is called after device_generic_init()
- update the device_generic_init() method of all concerned classes
- doing only a return file_dev::device_specific_init(); in child class is
  useless (not overwriting the method would be ok) but I want to be
  sure that nobody will forget to do it if device_specific_init() is
  modified
- testing can be done by searching for "Ready to append to end of Volume"
  in job log of "tests/restart-job-test"
bacula/src/stored/cloud_dev.c
bacula/src/stored/cloud_dev.h
bacula/src/stored/fifo_dev.c
bacula/src/stored/fifo_dev.h
bacula/src/stored/file_dev.c
bacula/src/stored/file_dev.h
bacula/src/stored/init_dev.c
bacula/src/stored/win_file_dev.h