Skip to content

Commit

Permalink
Merge pull request #24 from ixs/prevent_break_when_size_unsupported
Browse files Browse the repository at this point in the history
Prevent BareosFdMySQL breaking if size calculation goes wrong
  • Loading branch information
aussendorf committed Oct 4, 2017
2 parents 41d6408 + cfa5ca4 commit 63b0192
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion fd-plugins/mysql-python/BareosFdMySQLclass.py
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,10 @@ def start_backup_file(self,context, savepkt):

statp = StatPacket()
if not size_curr_db == "NULL\n":
statp.size = int(size_curr_db)
try:
statp.size = int(size_curr_db)
except ValueError:
pass
savepkt.statp = statp
savepkt.fname = "/_mysqlbackups_/"+db+".sql"
savepkt.type = bFileType['FT_REG']
Expand Down

0 comments on commit 63b0192

Please sign in to comment.