comparison src/msg.cpp @ 315:3e6cdd543857

date sent property is fixed size, so the value is stored directly in the property stream
author Carl Byington <carl@five-ten-sg.com>
date Thu, 03 Jun 2010 19:09:29 -0700
parents 6bf6b60a9751
children c5e7f13d2836
comparison
equal deleted inserted replaced
314:6bf6b60a9751 315:3e6cdd543857
121 p.reserved = 0; 121 p.reserved = 0;
122 prop.push_back(p); 122 prop.push_back(p);
123 } 123 }
124 124
125 125
126 static void string_property(GsfOutfile *out, property_list &prop, uint32_t tag, FILETIME *contents);
127 static void string_property(GsfOutfile *out, property_list &prop, uint32_t tag, FILETIME *contents) {
128 if (contents) {
129 string_property(out, prop, tag, (char *)contents, sizeof(FILETIME));
130 }
131 }
132
133
134 static void string_property(GsfOutfile *out, property_list &prop, uint32_t tag, const char* charset, pst_string &contents); 126 static void string_property(GsfOutfile *out, property_list &prop, uint32_t tag, const char* charset, pst_string &contents);
135 static void string_property(GsfOutfile *out, property_list &prop, uint32_t tag, const char* charset, pst_string &contents) { 127 static void string_property(GsfOutfile *out, property_list &prop, uint32_t tag, const char* charset, pst_string &contents) {
136 if (contents.str) { 128 if (contents.str) {
137 convert_8bit(contents, charset); 129 convert_8bit(contents, charset);
138 string_property(out, prop, tag, contents.str, strlen(contents.str)); 130 string_property(out, prop, tag, contents.str, strlen(contents.str));
180 p.tag = tag; 172 p.tag = tag;
181 p.flags = flags; 173 p.flags = flags;
182 p.length = value; 174 p.length = value;
183 p.reserved = 0; 175 p.reserved = 0;
184 prop_list.push_back(p); 176 prop_list.push_back(p);
177 }
178
179
180 static void i64_property(property_list &prop_list, uint32_t tag, uint32_t flags, FILETIME *value);
181 static void i64_property(property_list &prop_list, uint32_t tag, uint32_t flags, FILETIME *value) {
182 if (value) {
183 property p;
184 p.tag = tag;
185 p.flags = flags;
186 p.length = value->dwLowDateTime;
187 p.reserved = value->dwHighDateTime;
188 prop_list.push_back(p);
189 }
185 } 190 }
186 191
187 192
188 static void nzi_property(property_list &prop_list, uint32_t tag, uint32_t flags, uint32_t value); 193 static void nzi_property(property_list &prop_list, uint32_t tag, uint32_t flags, uint32_t value);
189 static void nzi_property(property_list &prop_list, uint32_t tag, uint32_t flags, uint32_t value) { 194 static void nzi_property(property_list &prop_list, uint32_t tag, uint32_t flags, uint32_t value) {
244 nzi_property(prop_list, 0x002E0003, 0x6, email.original_sensitivity); 249 nzi_property(prop_list, 0x002E0003, 0x6, email.original_sensitivity);
245 nzi_property(prop_list, 0x00360003, 0x6, email.sensitivity); 250 nzi_property(prop_list, 0x00360003, 0x6, email.sensitivity);
246 nzi_property(prop_list, 0x0C17000B, 0x6, email.reply_requested); 251 nzi_property(prop_list, 0x0C17000B, 0x6, email.reply_requested);
247 nzi_property(prop_list, 0x0E01000B, 0x6, email.delete_after_submit); 252 nzi_property(prop_list, 0x0E01000B, 0x6, email.delete_after_submit);
248 int_property(prop_list, 0x0E070003, 0x6, item->flags); 253 int_property(prop_list, 0x0E070003, 0x6, item->flags);
254 i64_property(prop_list, 0x00390040, 0x6, email.sent_date);
249 GsfOutfile *out = GSF_OUTFILE (output); 255 GsfOutfile *out = GSF_OUTFILE (output);
250 string_property(out, prop_list, 0x001A001E, item->ascii_type); 256 string_property(out, prop_list, 0x001A001E, item->ascii_type);
251 string_property(out, prop_list, 0x0037001E, body_charset, item->subject); 257 string_property(out, prop_list, 0x0037001E, body_charset, item->subject);
252 string_property(out, prop_list, 0x00390040, email.sent_date);
253 strin0_property(out, prop_list, 0x003B0102, body_charset, email.outlook_sender); 258 strin0_property(out, prop_list, 0x003B0102, body_charset, email.outlook_sender);
254 string_property(out, prop_list, 0x003D001E, string("")); 259 string_property(out, prop_list, 0x003D001E, string(""));
255 string_property(out, prop_list, 0x0040001E, body_charset, email.outlook_received_name1); 260 string_property(out, prop_list, 0x0040001E, body_charset, email.outlook_received_name1);
256 string_property(out, prop_list, 0x0042001E, body_charset, email.outlook_sender_name); 261 string_property(out, prop_list, 0x0042001E, body_charset, email.outlook_sender_name);
257 string_property(out, prop_list, 0x0044001E, body_charset, email.outlook_recipient_name); 262 string_property(out, prop_list, 0x0044001E, body_charset, email.outlook_recipient_name);