From dadb05b0afc9a76d4f29a8d35bdf268aa20926df Mon Sep 17 00:00:00 2001
From: alecpl <alec@alec.pl>
Date: Fri, 27 Mar 2009 11:22:43 -0400
Subject: [PATCH] - Fix TNEF implementation bug (#1485773)
---
CHANGELOG | 1 +
program/lib/tnef_decoder.inc | 10 +++++-----
2 files changed, 6 insertions(+), 5 deletions(-)
diff --git a/CHANGELOG b/CHANGELOG
index 561f22f..0e9ccfd 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1,6 +1,7 @@
CHANGELOG RoundCube Webmail
===========================
+- Fix TNEF implementation bug (#1485773)
- Fix incorrect row id parsing for LDAP contacts list (#1485784)
- Fix 'mode' parameter in sqlite DSN (#1485772)
diff --git a/program/lib/tnef_decoder.inc b/program/lib/tnef_decoder.inc
index f9b7c36..8e3682a 100644
--- a/program/lib/tnef_decoder.inc
+++ b/program/lib/tnef_decoder.inc
@@ -102,7 +102,7 @@
function tnef_decode_attribute($attribute, &$buf)
{
- global $debug, $download;
+ global $debug;
$length = tnef_geti32($buf);
$value = tnef_getx($length, $buf); //data
@@ -116,9 +116,9 @@
switch($attribute)
{
case TNEF_BODYTEXT:
- if (!$download)
+ if ($debug)
{
- printf("<b>Embedded message:</b><pre>%s</pre>",$value);
+ printf("<b>Embedded message:</b><pre>%s</pre>", $value);
}
break;
@@ -195,7 +195,7 @@
case TNEF_MAPI_ATTACH_DATA:
tnef_getx(16, $value); // skip the next 16 bytes (unknown data)
- array_shift($attachment_data); // eliminate the current (bogus) attachment
+ array_shift($attachment_data); // eliminate the current (bogus) attachment
do_tnef_decode($value, $attachment_data); // recursively process the attached message
break;
@@ -349,4 +349,4 @@
}
-?>
\ No newline at end of file
+?>
--
Gitblit v1.9.1