the function user_files_check_backup() is used by the backup_check and backup_scheduled.php files to display how many user files will be backed up.
It is looking at the old dataroot. "/users" directory which from what I understand from
MDL-8605 is no longer used to store files (and in a fresh 1.9 install it's unlikely that the folder will actually be created!
This displays bad information to the user when running a manual backup - eg it will always display 0 user files to be backed up for fresh moodle 1.9+ installs.
The actual Backup_execute doesn't use the function so it doesn't affect the actual backup except that it can run some really badly performing code taking up memory/processes. - if that directory contains data from an old moodle version that hasn't been deleted, then it can result in thousands of useless db queries (see
will write a patch to get this information from the new "user" directory and submit for review.