[libpst-commits] r80 - trunk

Chris Halls halls at alioth.debian.org
Tue Jan 9 16:36:03 CET 2007


Author: halls
Date: 2007-01-09 16:36:03 +0100 (Tue, 09 Jan 2007)
New Revision: 80

Modified:
   trunk/libpst.c
Log:
Initialise variables that can be read from before they are written to if there are problems reading from PST file


Index: trunk/libpst.c
===================================================================
--- trunk/libpst.c	(revision 79)
+++ trunk/libpst.c	(revision 80)
@@ -287,7 +287,7 @@
 int32_t pst_attach_to_file_base64(pst_file *pf, pst_item_attach *attach, FILE* fp) {
   pst_index_ll *ptr;
   struct holder h = {NULL, fp, 1, "", 0};
-  int32_t size;
+  int32_t size = 0;
   char *c;
   DEBUG_ENT("pst_attach_to_file_base64");
   if (attach->id_val != -1) {
@@ -377,10 +377,10 @@
   pst_desc_ll *p;
   pst_num_array *na;
   //  pst_index_ll *list;
-  pst_index2_ll *list2;
+  pst_index2_ll *list2=NULL;
   unsigned char * buffer=NULL, *headerbuffer=NULL;//, *tc;
   pst_x_attrib xattrib;
-  int32_t bptr = 0, bsize, hsize, tint, err=0, x;
+  int32_t bptr = 0, bsize=0, hsize=0, tint, err=0, x;
   pst_x_attrib_ll *ptr, *p_head=NULL, *p_sh=NULL, *p_sh2=NULL;
 
   DEBUG_ENT("pst_loadExtendedAttributes");



More information about the libpst-commits mailing list