libpst

changeset 290:fec37c150982

possible fix for corrupted output forking for separate messages
author Carl Byington <carl@five-ten-sg.com>
date Sat Jun 04 10:52:47 2011 -0700 (11 months ago)
parents cc8ee701f190
children bc23fba0da8e
files src/readpst.c xml/libpst.in
line diff
     1.1 --- a/src/readpst.c	Fri May 27 11:36:49 2011 -0700
     1.2 +++ b/src/readpst.c	Sat Jun 04 10:52:47 2011 -0700
     1.3 @@ -330,8 +330,9 @@
     1.4                      DEBUG_INFO(("I have an email type %"PRIi32", but the folder type %"PRIi32" isn't an email folder. Skipping it\n", item->type, ff.type));
     1.5                  }
     1.6                  else {
     1.7 +                    char *extra_mime_headers = NULL;
     1.8                      ff.item_count++;
     1.9 -                    char *extra_mime_headers = NULL;
    1.10 +                    if (mode == MODE_SEPARATE) mk_separate_file(&ff, (mode_EX) ? ".eml" : "");
    1.11                      if (mode == MODE_SEPARATE) {
    1.12                          // process this single email message, possibly forking
    1.13                          pid_t parent = getpid();
    1.14 @@ -339,7 +340,6 @@
    1.15                          if (child == 0) {
    1.16                              // we are the child process, or the original parent if no children were available
    1.17                              pid_t me = getpid();
    1.18 -                            mk_separate_file(&ff, (mode_EX) ? ".eml" : "");
    1.19                              write_normal_email(ff.output, ff.name, item, mode, mode_MH, &pstfile, save_rtf_body, &extra_mime_headers);
    1.20  #ifdef HAVE_FORK
    1.21  #ifdef HAVE_SEMAPHORE_H
     2.1 --- a/xml/libpst.in	Fri May 27 11:36:49 2011 -0700
     2.2 +++ b/xml/libpst.in	Sat Jun 04 10:52:47 2011 -0700
     2.3 @@ -35,7 +35,7 @@
     2.4  
     2.5      <refentry id="readpst.1">
     2.6          <refentryinfo>
     2.7 -            <date>2009-09-14</date>
     2.8 +            <date>2011-05-27</date>
     2.9          </refentryinfo>
    2.10  
    2.11          <refmeta>
    2.12 @@ -155,7 +155,9 @@
    2.13                      <term>-j <replaceable class="parameter">jobs</replaceable></term>
    2.14                      <listitem><para>
    2.15                          Specifies the maximum number of parallel jobs. Specify 0 to suppress
    2.16 -                        running parallel jobs.
    2.17 +                        running parallel jobs. Folders may be processed in parallel. Output
    2.18 +                        formats that place each mail message in a separate file (-M, -S, -e)
    2.19 +                        may process the contents of individual folders in parallel.
    2.20                      </para></listitem>
    2.21                  </varlistentry>
    2.22                  <varlistentry>
    2.23 @@ -269,7 +271,7 @@
    2.24  
    2.25      <refentry id="lspst.1">
    2.26          <refentryinfo>
    2.27 -            <date>2009-09-14</date>
    2.28 +            <date>2011-05-27</date>
    2.29          </refentryinfo>
    2.30  
    2.31          <refmeta>
    2.32 @@ -364,7 +366,7 @@
    2.33  
    2.34      <refentry id="pst2ldif.1">
    2.35          <refentryinfo>
    2.36 -            <date>2009-09-14</date>
    2.37 +            <date>2011-05-27</date>
    2.38          </refentryinfo>
    2.39  
    2.40          <refmeta>
    2.41 @@ -532,7 +534,7 @@
    2.42  
    2.43      <refentry id="pst2dii.1">
    2.44          <refentryinfo>
    2.45 -            <date>2009-09-14</date>
    2.46 +            <date>2011-05-27</date>
    2.47          </refentryinfo>
    2.48  
    2.49          <refmeta>
    2.50 @@ -665,7 +667,7 @@
    2.51  
    2.52      <refentry id="pst.5">
    2.53          <refentryinfo>
    2.54 -            <date>2009-09-14</date>
    2.55 +            <date>2011-05-27</date>
    2.56          </refentryinfo>
    2.57  
    2.58          <refmeta>