Merged [18345]: Close a small leak when deleting logs from the log viewer