Project

General

Profile

Actions

Bug #12857

closed

Generic method "File_remove" can delete empty directories

Added by Félix DALLIDET almost 6 years ago. Updated almost 2 years ago.

Status:
Released
Priority:
N/A
Category:
Generic methods
Target version:
Severity:
UX impact:
User visibility:
Effort required:
Very Small
Priority:
0
Name check:
Fix check:
Regression:

Description

if we build a dir like this:

mkdir /tmp/toRemove

Apply a directive based from the GM "file_absent" on the file "/tmp/toRemove", Rudder will remove the folder.
Now, if we make the same directory and add a file in it:

mkdir /tmp/toRemove
touch /tmp/toRemove/afile

Rudder does not remove the directory but returns a compliant report.

This is most likely unwanted.

Actions

Also available in: Atom PDF