projects
/
squirrelmail.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Always display $org_name in the title
[squirrelmail.git]
/
plugins
/
mail_fetch
/
class.POP3.php
diff --git
a/plugins/mail_fetch/class.POP3.php
b/plugins/mail_fetch/class.POP3.php
index 7305431897b3a23cd0cedb306aaa40fd71fee0e2..046bb77cdb954cd4f8766176681c3e37fdf905c5 100644
(file)
--- a/
plugins/mail_fetch/class.POP3.php
+++ b/
plugins/mail_fetch/class.POP3.php
@@
-3,7
+3,7
@@
/**
* mail_fetch/setup.php
*
/**
* mail_fetch/setup.php
*
- * Copyright (c) 1999-200
3
The SquirrelMail Project Team
+ * Copyright (c) 1999-200
4
The SquirrelMail Project Team
*
* Copyright (c) 1999 CDI (cdi@thewebmasters.net) All Rights Reserved
* Modified by Philippe Mingo 2001 mingo@rotedic.com
*
* Copyright (c) 1999 CDI (cdi@thewebmasters.net) All Rights Reserved
* Modified by Philippe Mingo 2001 mingo@rotedic.com
@@
-62,13
+62,15
@@
class POP3 {
if(!empty($timeout)) {
settype($timeout,"integer");
$this->TIMEOUT = $timeout;
if(!empty($timeout)) {
settype($timeout,"integer");
$this->TIMEOUT = $timeout;
- set_time_limit($timeout);
+ if (!ini_get('safe_mode'))
+ set_time_limit($timeout);
}
return true;
}
function update_timer () {
}
return true;
}
function update_timer () {
- set_time_limit($this->TIMEOUT);
+ if (!ini_get('safe_mode'))
+ set_time_limit($this->TIMEOUT);
return true;
}
return true;
}
@@
-88,7
+90,7
@@
class POP3 {
return false;
}
return false;
}
- $fp = fsockopen("$server", $port, $errno, $errstr);
+ $fp =
@
fsockopen("$server", $port, $errno, $errstr);
if(!$fp) {
$this->ERROR = _("POP3 connect:") . ' ' . _("Error ") . "[$errno] [$errstr]";
if(!$fp) {
$this->ERROR = _("POP3 connect:") . ' ' . _("Error ") . "[$errno] [$errstr]";
@@
-304,7
+306,7
@@
class POP3 {
$this->ERROR = _("POP3 pop_list:") . ' ' . _("Error ") . "[$reply]";
return false;
}
$this->ERROR = _("POP3 pop_list:") . ' ' . _("Error ") . "[$reply]";
return false;
}
- list($junk,$num,$size) =
explode(" "
,$reply);
+ list($junk,$num,$size) =
preg_split('/\s+/'
,$reply);
return $size;
}
$cmd = "LIST";
return $size;
}
$cmd = "LIST";
@@
-327,7
+329,7
@@
class POP3 {
$this->ERROR = _("POP3 pop_list:") . ' ' . _("Premature end of list");
return false;
}
$this->ERROR = _("POP3 pop_list:") . ' ' . _("Premature end of list");
return false;
}
- list($thisMsg,$msgSize) =
explode(" "
,$line);
+ list($thisMsg,$msgSize) =
preg_split('/\s+/'
,$line);
settype($thisMsg,"integer");
if($thisMsg != $msgC)
{
settype($thisMsg,"integer");
if($thisMsg != $msgC)
{
@@
-397,7
+399,7
@@
class POP3 {
return $last;
}
return $last;
}
- $Vars =
explode(" "
,$reply);
+ $Vars =
preg_split('/\s+/'
,$reply);
$count = $Vars[1];
$size = $Vars[2];
settype($count,"integer");
$count = $Vars[1];
$size = $Vars[2];
settype($count,"integer");
@@
-528,7
+530,7
@@
class POP3 {
$this->ERROR = _("POP3 uidl:") . ' ' . _("Error ") . "[$reply]";
return false;
}
$this->ERROR = _("POP3 uidl:") . ' ' . _("Error ") . "[$reply]";
return false;
}
- list ($ok,$num,$myUidl) =
explode(" "
,$reply);
+ list ($ok,$num,$myUidl) =
preg_split('/\s+/'
,$reply);
return $myUidl;
} else {
$this->update_timer();
return $myUidl;
} else {
$this->update_timer();
@@
-559,7
+561,7
@@
class POP3 {
if(ereg("^\.\r\n",$line)) {
break;
}
if(ereg("^\.\r\n",$line)) {
break;
}
- list ($msg,$msgUidl) =
explode(" "
,$line);
+ list ($msg,$msgUidl) =
preg_split('/\s+/'
,$line);
$msgUidl = $this->strip_clf($msgUidl);
if($count == $msg) {
$UIDLArray[$msg] = $msgUidl;
$msgUidl = $this->strip_clf($msgUidl);
if($count == $msg) {
$UIDLArray[$msg] = $msgUidl;