Added a check in sqimap_login to verify $onetimepad is set. Not sure why
authorjangliss <jangliss@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Thu, 9 Jan 2003 20:12:40 +0000 (20:12 +0000)
committerjangliss <jangliss@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Thu, 9 Jan 2003 20:12:40 +0000 (20:12 +0000)
no check was ensured before.  Should make plugin developers a little happier
in some cases too.

git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@4406 7612ce4b-ef26-0410-bec9-ea0150e637f0

functions/imap_general.php

index 4a97406..4ff9604 100755 (executable)
@@ -213,6 +213,9 @@ function sqimap_read_data ($imap_stream, $pre, $handle_errors, &$response, &$mes
 function sqimap_login ($username, $password, $imap_server_address, $imap_port, $hide) {
     global $color, $squirrelmail_language, $onetimepad, $use_imap_tls, $imap_auth_mech;
 
+    if (!isset($onetimepad) || empty($onetimepad)) {
+        sqgetglobalvar('onetimepad' , $onetimepad , SQ_SESSION );
+    }
     $imap_server_address = sqimap_get_user_server($imap_server_address, $username);
        $host=$imap_server_address;