Ticket #3209: fix crash when file(s) deleting.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
Merge branch '3209_delete_crash'

* 3209_delete_crash:
  Ticket #3209: fix crash when file(s) deleting.