warnings removed
authorlkehresman <lkehresman@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Thu, 1 Feb 2001 05:06:58 +0000 (05:06 +0000)
committerlkehresman <lkehresman@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Thu, 1 Feb 2001 05:06:58 +0000 (05:06 +0000)
git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@1028 7612ce4b-ef26-0410-bec9-ea0150e637f0

functions/smtp.php
src/compose.php

index cae5cbc..b0b922f 100644 (file)
       global $data_dir, $username, $domain, $key, $version, $sent_folder, $imapServerAddress, $imapPort;
       $more_headers = Array();
 
+      // added as just a precaution (Luke: 1.0.1)
+      $t = trim($t);
+      $c = trim($c);
+      $b = trim($b);
+      $subject = trim($subject);
+      $body = trim($body);
+      $mailbox = trim($mailbox);
+      $sent_folder = trim($sent_folder);
+
       $imap_stream = sqimap_login($username, $key, $imapServerAddress, $imapPort, 1);
 
       if ($reply_id) {
index 42cb5b4..5acb8cb 100644 (file)
       }
     }
 
-   $mailbox = trim($mailbox);
-   $send_to = trim($send_to);
-   $send_to_cc = trim($send_to_cc);
-   $send_to_bcc = trim($send_to_bcc);
-   $subject = trim($subject);
-   $body = trim($body);
-   $attachfile = trim($attachfile);
+   if (isset($mailbox))     $mailbox = trim($mailbox);
+   if (isset($send_to))     $send_to = trim($send_to);
+   if (isset($send_to_cc))  $send_to_cc = trim($send_to_cc);
+   if (isset($send_to_bcc)) $send_to_bcc = trim($send_to_bcc);
+   if (isset($subject))     $subject = trim($subject);
+   if (isset($body))        $body = trim($body);
+   if (isset($attachfile))  $attachfile = trim($attachfile);
    
    if (!isset($mailbox) || $mailbox == "" || ($mailbox == "None"))
       $mailbox = "INBOX";