Mercurial > libpst
changeset 377:506e266f930d
Vitaliy Didik - fix MSVC build
author | Carl Byington <carl@five-ten-sg.com> |
---|---|
date | Mon, 20 Nov 2017 08:19:28 -0800 |
parents | b58ca528f5c9 |
children | ad7b880ad3d1 |
files | AUTHORS regression/regression-tests.bash src/common.h src/define.h |
diffstat | 4 files changed, 52 insertions(+), 51 deletions(-) [+] |
line wrap: on
line diff
--- a/AUTHORS Fri Jul 21 21:35:01 2017 -0700 +++ b/AUTHORS Mon Nov 20 08:19:28 2017 -0800 @@ -41,6 +41,8 @@ Jeffrey Morlan <jeffrey@everlaw.com> Hans Liss <Hans@Liss.pp.se> Igor Stroh <igor.stroh@rulim.de> + Zachary Travis <ztravis@everlaw.com> + Vitaliy Didik <ariman@inbox.ru> Testing team: Mac OSX - Michael Watson <mike@mikeandgayle.com>
--- a/regression/regression-tests.bash Fri Jul 21 21:35:01 2017 -0700 +++ b/regression/regression-tests.bash Mon Nov 20 08:19:28 2017 -0800 @@ -81,16 +81,16 @@ # $val ../src/readpst $utf $acc -C $char -j 0 -k -cv -o output$n -d $ba.log $fn >$ba.err 2>&1 ## recursive mode - #echo $val ../src/readpst $utf $acc -C $char -j 0 -r -cv -o output$n -d $ba.log $fn - # $val ../src/readpst $utf $acc -C $char -j 0 -r -cv -o output$n -d $ba.log $fn >$ba.err 2>&1 + echo $val ../src/readpst $utf $acc -C $char -j 0 -r -cv -o output$n -d $ba.log $fn + $val ../src/readpst $utf $acc -C $char -j 0 -r -cv -o output$n -d $ba.log $fn >$ba.err 2>&1 ## separate mode with filename extensions and .msg files #echo $val ../src/readpst $jobs -r -m -D -cv -o output$n -d $ba.log $fn # $val ../src/readpst $jobs -r -m -D -cv -o output$n -d $ba.log $fn >$ba.err 2>&1 ## separate mode where we decode all attachments to binary files - echo $val ../src/readpst $jobs -r -S -D -cv -o output$n -d $ba.log $fn - $val ../src/readpst $jobs -r -S -D -cv -o output$n -d $ba.log $fn >$ba.err 2>&1 + #echo $val ../src/readpst $jobs -r -S -D -cv -o output$n -d $ba.log $fn + # $val ../src/readpst $jobs -r -S -D -cv -o output$n -d $ba.log $fn >$ba.err 2>&1 ## testing idblock #../src/getidblock -p $fn 0 >$ba.fulldump @@ -122,37 +122,37 @@ [ "$2" == "reg" ] && regression="yes" [ "$regression" == "yes" ] && val="" -# $func 1 ams.pst -# $func 2 sample_64.pst -# $func 3 test.pst -# $func 4 big_mail.pst -# $func 5 mbmg.archive.pst -# $func 6 Single2003-read.pst -# $func 7 Single2003-unread.pst -# $func 8 ol2k3high.pst -# $func 9 ol97high.pst -# $func 10 returned_message.pst -# $func 11 flow.pst -# $func 12 test-html.pst -# $func 13 test-text.pst -# $func 14 joe.romanowski.pst -# $func 15 hourig1.pst -# $func 16 test-mac.pst -# $func 17 backup.pst -# $func 18 spam.pst -# $func 19 rendgen.pst # single email appointment -# $func 20 rendgen2.pst # email appointment with no termination date -# $func 21 rendgen3.pst # mime signed email - $func 22 rendgen4.pst # appointment test cases -# $func 23 rendgen5.pst # appointment test cases -# $func 24 paul.sheer.pst # embedded rfc822 attachment -# $func 25 jerry.pst # non ascii subject lines -# $func 26 phill.bertolus.pst # possible segfault in forked process, cannot reproduce -# $func 27 kaiser.pst # appointments with other character sets -# $func 28 pstsample.pst # character set issue -# $func 29 pstsample2.pst # embedded image in rtf data -# $func 30 pstsample3.pst # exports of rtf and html -# $func 31 Journal_Archives_08_29_2010.pst +$func 1 ams.pst +$func 2 sample_64.pst +$func 3 test.pst +$func 4 big_mail.pst +$func 5 mbmg.archive.pst +$func 6 Single2003-read.pst +$func 7 Single2003-unread.pst +$func 8 ol2k3high.pst +$func 9 ol97high.pst +$func 10 returned_message.pst +$func 11 flow.pst +$func 12 test-html.pst +$func 13 test-text.pst +$func 14 joe.romanowski.pst +$func 15 hourig1.pst +$func 16 test-mac.pst +$func 17 backup.pst +$func 18 spam.pst +$func 19 rendgen.pst # single email appointment +$func 20 rendgen2.pst # email appointment with no termination date +$func 21 rendgen3.pst # mime signed email +$func 22 rendgen4.pst # appointment test cases +$func 23 rendgen5.pst # appointment test cases +$func 24 paul.sheer.pst # embedded rfc822 attachment +$func 25 jerry.pst # non ascii subject lines +$func 26 phill.bertolus.pst # possible segfault in forked process, cannot reproduce +$func 27 kaiser.pst # appointments with other character sets +$func 28 pstsample.pst # character set issue +$func 29 pstsample2.pst # embedded image in rtf data +$func 30 pstsample3.pst # exports of rtf and html +$func 31 Journal_Archives_08_29_2010.pst [ -n "$val" ] && grep 'lost:' *err | grep -v 'lost: 0 '
--- a/src/common.h Fri Jul 21 21:35:01 2017 -0700 +++ b/src/common.h Mon Nov 20 08:19:28 2017 -0800 @@ -9,18 +9,18 @@ #include <time.h> -#ifndef _MSC_VER +#if !defined(_MSC_VER) || (_MSC_VER >= 1800) #include <stdint.h> #include <inttypes.h> #else typedef signed char int8_t; typedef unsigned char uint8_t; - typedef unsigned short uint16_t; - typedef short int16_t; + typedef unsigned short uint16_t; + typedef short int16_t; typedef unsigned int uint32_t; - typedef int int32_t; - typedef unsigned long long uint64_t; - typedef long long int64_t; + typedef int int32_t; + typedef unsigned long long uint64_t; + typedef long long int64_t; #endif #ifndef _WIN32
--- a/src/define.h Fri Jul 21 21:35:01 2017 -0700 +++ b/src/define.h Mon Nov 20 08:19:28 2017 -0800 @@ -74,13 +74,12 @@ #else #error Only MSC and mingw supported for Windows #endif - #ifndef __MINGW32__ - #define size_t __int64 - #endif #ifndef UINT64_MAX #define UINT64_MAX ((uint64_t)0xffffffffffffffff) #endif - #define PRIx64 "I64x" + #ifndef PRIx64 + #define PRIx64 "I64x" + #endif int __cdecl _fseeki64(FILE *, __int64, int); __int64 __cdecl _ftelli64(FILE *); @@ -97,7 +96,7 @@ #ifdef __DJGPP__ #define gmtime_r(tp,tmp) (gmtime(tp)?(*(tmp)=*gmtime(tp),(tmp)):0) #define ctime_r(tp,tmp) (ctime(tp)?(strcpy((tmp),ctime((tp))),(tmp)):0) - #define fseeko(stream, offset, whence) fseek(stream, (long)offset, whence) + #define fseeko(stream, offset, whence) fseek(stream, (long)offset, whence) #define ftello ftell #endif #ifdef HAVE_UNISTD_H @@ -151,7 +150,7 @@ #define MESSAGEPRINT3(...) pst_debug(3, __LINE__, __FILE__, __VA_ARGS__) #define WARN(x) { \ - MESSAGEPRINT3 x; \ + MESSAGEPRINT3 x; \ pst_debug_lock(); \ printf x; \ fflush(stdout); \ @@ -172,12 +171,12 @@ #define DEBUG_ENT(x) \ { \ pst_debug_func(1, x); \ - pst_debug(1, __LINE__, __FILE__, "Entering function\n"); \ + pst_debug(1, __LINE__, __FILE__, "Entering function\n"); \ } #define DEBUG_RET() \ { \ pst_debug(1, __LINE__, __FILE__, "Leaving function\n"); \ - pst_debug_func_ret(1); \ + pst_debug_func_ret(1); \ } #define DEBUG_INIT(fname,mutex) {pst_debug_init(fname,mutex);} @@ -245,11 +244,11 @@ (((uint8_t const *)(p))[2] << 16) | \ (((uint8_t const *)(p))[3] << 24)) -#define PST_LE_GET_UINT16(p) \ +#define PST_LE_GET_UINT16(p) \ (uint16_t)((((uint8_t const *)(p))[0] << 0) | \ (((uint8_t const *)(p))[1] << 8)) -#define PST_LE_GET_INT16(p) \ +#define PST_LE_GET_INT16(p) \ (int16_t)((((uint8_t const *)(p))[0] << 0) | \ (((uint8_t const *)(p))[1] << 8))