Re: Something amiss in bacula-9.6.7: Possible race condition

Phil Stracchino <[email protected]>
Newsgroups gmane.comp.sysutils.backup.bacula.devel
Organization Babylon Communications
Message-ID <[email protected]>
On 1/15/21 2:18 PM, Phil Stracchino wrote:
> If we INSERT IGNORE and there IS an existing matching record, then the
> record is NOT inserted, no error is thrown, but mysql_affected_rows()
> and mysql_insert_id() both return 0, and so does
> sql_insert_autokey_record().


Footnote I omitted:  while my patch shouldn't break anything, it won't
work on its own *anyway* because sql_insert_autokey_record() will still
fail.


-- 
  Phil Stracchino
  Babylon Communications
  [email protected]
  [email protected]
  Landline: +1.603.293.8485
  Mobile:   +1.603.998.6958
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.