Reading the User's Home Directory



if (defined($homes{$home})) {
        print "    $name shares a home dir with $homes{$home}.\n";
}
else {
        #
        # Scan the users home directory looking for
        # files owned by someone else, and checking
        # the amount of space used.
        $homes{$home} = $name;
        # Checks the total space used by a subdir, and the access time
        # of the newest file in that dir.
        $latest = $filesize = $badowner = 0;
        open(FIND, "find $home -maxdepth $MAXDEPTH -printf
                \"%p-XQC-%k-XQC-%u-XQC-%C@\n\" |") ||die "Unable to open find";
 

/home/randy-XQC-6-XQC-randy-XQC-966999751
/home/randy/.bash_history-XQC-24-XQC-randy-XQC-966975752
/home/randy/.kderc-XQC-1-XQC-randy-XQC-966991087
/home/randy/.xauth-XQC-1-XQC-randy-XQC-948230682
/home/randy/.xauth/refcount-XQC-1-XQC-randy-XQC-952494615
/home/randy/.xauth/refcount/root-XQC-1-XQC-randy-XQC-965633417
/home/randy/.xauth/refcount/nobody-XQC-1-XQC-randy-XQC-952494615
/home/randy/mbox-XQC-882-XQC-randy-XQC-966993329
/home/randy/.kde-XQC-1-XQC-randy-XQC-965375952
/home/randy/.kde/Autostart-XQC-1-XQC-randy-XQC-965375960