aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaul Bolle <pebolle@tiscali.nl>2009-12-18 20:55:05 +0800
committerPaul Bolle <pebolle@tiscali.nl>2009-12-18 20:57:59 +0800
commitf148a0b0e3aaee26c42c7fc03f7a6359ead71abb (patch)
tree549e34a061f1f8c46296b2740045efaa67b5c122
parent5341a35f20dee167645b05d73fa3cfb23127d61f (diff)
downloadgsoc2013-evolution-f148a0b0e3aaee26c42c7fc03f7a6359ead71abb.tar
gsoc2013-evolution-f148a0b0e3aaee26c42c7fc03f7a6359ead71abb.tar.gz
gsoc2013-evolution-f148a0b0e3aaee26c42c7fc03f7a6359ead71abb.tar.bz2
gsoc2013-evolution-f148a0b0e3aaee26c42c7fc03f7a6359ead71abb.tar.lz
gsoc2013-evolution-f148a0b0e3aaee26c42c7fc03f7a6359ead71abb.tar.xz
gsoc2013-evolution-f148a0b0e3aaee26c42c7fc03f7a6359ead71abb.tar.zst
gsoc2013-evolution-f148a0b0e3aaee26c42c7fc03f7a6359ead71abb.zip
Bug #603701 - Don't treat 4 byte values as DDWORDs
The values of PT_LONG and PT_BOOLEAN MAPI tags are 4 byte wide so they should be accessed as DWORDs.
-rw-r--r--plugins/tnef-attachments/tnef-plugin.c24
1 files changed, 12 insertions, 12 deletions
diff --git a/plugins/tnef-attachments/tnef-plugin.c b/plugins/tnef-attachments/tnef-plugin.c
index f18b90b144..59b0d4f230 100644
--- a/plugins/tnef-attachments/tnef-plugin.c
+++ b/plugins/tnef-attachments/tnef-plugin.c
@@ -843,8 +843,8 @@ void saveVCalendar(TNEFStruct *tnef, const gchar *tmpdir) {
gchar *charptr, *charptr2;
FILE *fptr;
gint index;
- DDWORD *ddword_ptr;
- DDWORD ddword_val;
+ DWORD *dword_ptr;
+ DWORD dword_val;
dtr thedate;
sprintf(ifilename, "%s/calendar.ics", tmpdir);
@@ -901,8 +901,8 @@ void saveVCalendar(TNEFStruct *tnef, const gchar *tmpdir) {
filename = NULL;
if ((filename=MAPIFindUserProp(&(tnef->MapiProperties),
PROP_TAG(PT_LONG, 0x8201))) != MAPI_UNDEFINED) {
- ddword_ptr = (DDWORD*)filename->data;
- fprintf(fptr, "SEQUENCE:%i\n", (gint) *ddword_ptr);
+ dword_ptr = (DWORD*)filename->data;
+ fprintf(fptr, "SEQUENCE:%i\n", (gint) *dword_ptr);
}
if ((filename=MAPIFindProperty(&(tnef->MapiProperties),
PROP_TAG(PT_BINARY, PR_SENDER_SEARCH_KEY)))
@@ -1066,10 +1066,10 @@ void saveVCalendar(TNEFStruct *tnef, const gchar *tmpdir) {
filename = NULL;
if ((filename=MAPIFindUserProp(&(tnef->MapiProperties),
PROP_TAG(PT_BOOLEAN, 0x8506))) != MAPI_UNDEFINED) {
- ddword_ptr = (DDWORD*)filename->data;
- ddword_val = SwapDDWord((BYTE*)ddword_ptr);
+ dword_ptr = (DWORD*)filename->data;
+ dword_val = SwapDWord((BYTE*)dword_ptr);
fprintf(fptr, "CLASS:" );
- if (*ddword_ptr == 1) {
+ if (*dword_ptr == 1) {
fprintf(fptr,"PRIVATE\n");
} else {
fprintf(fptr,"PUBLIC\n");
@@ -1097,8 +1097,8 @@ void saveVTask(TNEFStruct *tnef, const gchar *tmpdir) {
gchar *charptr, *charptr2;
dtr thedate;
FILE *fptr;
- DDWORD *ddword_ptr;
- DDWORD ddword_val;
+ DWORD *dword_ptr;
+ DWORD dword_val;
vl = MAPIFindProperty(&(tnef->MapiProperties), PROP_TAG(PT_STRING8, PR_CONVERSATION_TOPIC));
@@ -1197,10 +1197,10 @@ void saveVTask(TNEFStruct *tnef, const gchar *tmpdir) {
filename = MAPIFindUserProp(&(tnef->MapiProperties), \
PROP_TAG(PT_BOOLEAN, 0x8506));
if (filename != MAPI_UNDEFINED) {
- ddword_ptr = (DDWORD*)filename->data;
- ddword_val = SwapDDWord((BYTE*)ddword_ptr);
+ dword_ptr = (DWORD*)filename->data;
+ dword_val = SwapDWord((BYTE*)dword_ptr);
fprintf(fptr, "CLASS:" );
- if (*ddword_ptr == 1) {
+ if (*dword_ptr == 1) {
fprintf(fptr,"PRIVATE\n");
} else {
fprintf(fptr,"PUBLIC\n");