[SUCS Devel] [Git][sucssite/sucs-site][beta] 2 commits: stop .forward file being a symlink

Imran Hussain imranh at sucs.org
Sat Apr 1 18:32:27 BST 2017


Imran Hussain pushed to branch beta at sucssite / sucs-site


Commits:
b13af1e6 by Chris Piper at 2017-03-31T14:06:03+01:00
stop .forward file being a symlink
- - - - -
92f40d62 by Imran Hussain at 2017-04-01T18:32:28+01:00
Merge branch 'master' into beta

- - - - -


1 changed file:

- lib/session.php


Changes:

=====================================
lib/session.php
=====================================
--- a/lib/session.php
+++ b/lib/session.php
@@ -228,7 +228,7 @@ class Session
         // the bash script returns 0 for no and 1 for yes, takes one arg, username
         $this->email = shell_exec("../plugins/sucsunreadmail $user");
 
-        if (file_exists($info['homedirectory'][0] . "/.forward")) {
+        if (file_exists($info['homedirectory'][0] . "/.forward") && ! is_link($info['homedirectory'][0] . "/.forward")) {
             $forward = file($info['homedirectory'][0] . "/.forward");
             $this->email_forward = preg_replace("/\n/", "", $forward[0]);
         }



View it on GitLab: https://projects.sucs.org/sucssite/sucs-site/compare/70eb93ea8e870a62d93bdf23798453be4d49956e...92f40d62319fdc7e651f769d7f33ef92b33b85f4
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sucs.org/pipermail/devel/attachments/20170401/5c33ea59/attachment.html>


More information about the Devel mailing list