Codebase list gtkwave / upstream/3.3.59
Imported Upstream version 3.3.59 أحمد المحمودي (Ahmed El-Mahmoudy) 10 years ago
15 changed file(s) with 228 addition(s) and 59 deletion(s). Raw diff Collapse all Expand all
14601460 Change [1] at end of struct to C99 [] notation with appropriate
14611461 allocation size modification.
14621462 System_profiler speed fix for OSX.
1463 3.3.59 26apr14 Use Duff's Device for 8 byte -> 1 byte binary value compression
1464 algorithm in FST writer.
1465 Warnings fixes from cppcheck.
1466 Moved MinGW for FST to using different windows tempfile
1467 generation instead of tmpfile().
1468 Removed fflush() in FST for MinGW in places that can cause
1469 crashes with read only files.
1470 Updated man page for gtkwave.1 indicating that XID is in hex.
1471 Allow decimal conversions on popcnt filtered vectors that are
1472 greater than 64 bits (they will never overflow).
00 ##########################################################################
11
2 GTKWave 3.3.58 Wave Viewer is Copyright (C) 1999-2014 Tony Bybell.
2 GTKWave 3.3.59 Wave Viewer is Copyright (C) 1999-2014 Tony Bybell.
33 Portions of GTKWave are Copyright (C) 1999-2014 Udi Finkelstein.
44 Context support is Copyright (C) 2007-2014 Kermin Elliott Fleming.
55 Trace group support is Copyright (C) 2009-2014 Donald Baltus.
00 #! /bin/sh
11 # Guess values for system-dependent variables and create Makefiles.
2 # Generated by GNU Autoconf 2.69 for gtkwave 3.3.58.
2 # Generated by GNU Autoconf 2.69 for gtkwave 3.3.59.
33 #
44 # Report bugs to <bybell@rocketmail.com>.
55 #
579579 # Identity of this package.
580580 PACKAGE_NAME='gtkwave'
581581 PACKAGE_TARNAME='gtkwave'
582 PACKAGE_VERSION='3.3.58'
583 PACKAGE_STRING='gtkwave 3.3.58'
582 PACKAGE_VERSION='3.3.59'
583 PACKAGE_STRING='gtkwave 3.3.59'
584584 PACKAGE_BUGREPORT='bybell@rocketmail.com'
585585 PACKAGE_URL=''
586586
13811381 # Omit some internal or obsolete options to make the list less imposing.
13821382 # This message is too long to be a string in the A/UX 3.1 sh.
13831383 cat <<_ACEOF
1384 \`configure' configures gtkwave 3.3.58 to adapt to many kinds of systems.
1384 \`configure' configures gtkwave 3.3.59 to adapt to many kinds of systems.
13851385
13861386 Usage: $0 [OPTION]... [VAR=VALUE]...
13871387
14471447
14481448 if test -n "$ac_init_help"; then
14491449 case $ac_init_help in
1450 short | recursive ) echo "Configuration of gtkwave 3.3.58:";;
1450 short | recursive ) echo "Configuration of gtkwave 3.3.59:";;
14511451 esac
14521452 cat <<\_ACEOF
14531453
15921592 test -n "$ac_init_help" && exit $ac_status
15931593 if $ac_init_version; then
15941594 cat <<\_ACEOF
1595 gtkwave configure 3.3.58
1595 gtkwave configure 3.3.59
15961596 generated by GNU Autoconf 2.69
15971597
15981598 Copyright (C) 2012 Free Software Foundation, Inc.
22362236 This file contains any messages produced by compilers while
22372237 running configure, to aid debugging if configure makes a mistake.
22382238
2239 It was created by gtkwave $as_me 3.3.58, which was
2239 It was created by gtkwave $as_me 3.3.59, which was
22402240 generated by GNU Autoconf 2.69. Invocation command line was
22412241
22422242 $ $0 $@
31033103
31043104 # Define the identity of the package.
31053105 PACKAGE='gtkwave'
3106 VERSION='3.3.58'
3106 VERSION='3.3.59'
31073107
31083108
31093109 cat >>confdefs.h <<_ACEOF
1095810958 # report actual input values of CONFIG_FILES etc. instead of their
1095910959 # values after options handling.
1096010960 ac_log="
10961 This file was extended by gtkwave $as_me 3.3.58, which was
10961 This file was extended by gtkwave $as_me 3.3.59, which was
1096210962 generated by GNU Autoconf 2.69. Invocation command line was
1096310963
1096410964 CONFIG_FILES = $CONFIG_FILES
1102411024 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
1102511025 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
1102611026 ac_cs_version="\\
11027 gtkwave config.status 3.3.58
11027 gtkwave config.status 3.3.59
1102811028 configured by $0, generated by GNU Autoconf 2.69,
1102911029 with options \\"\$ac_cs_config\\"
1103011030
11 # Process this file with autoconf to produce a configure script.
22
33 AC_PREREQ(2.59)
4 AC_INIT(gtkwave, 3.3.58, bybell@rocketmail.com)
4 AC_INIT(gtkwave, 3.3.59, bybell@rocketmail.com)
55 AC_CONFIG_SRCDIR([src/vcd.c])
66 AM_INIT_AUTOMAKE
77 AC_CONFIG_HEADER([config.h])
77 <key>CFBundleExecutable</key>
88 <string>gtkwave</string>
99 <key>CFBundleGetInfoString</key>
10 <string>3.3.58, (C) 1999-2014 Tony Bybell http://gtkwave.sourceforge.net</string>
10 <string>3.3.59, (C) 1999-2014 Tony Bybell http://gtkwave.sourceforge.net</string>
1111 <key>CFBundleIconFile</key>
1212 <string>gtkwave.icns</string>
1313 <key>CFBundleIdentifier</key>
1717 <key>CFBundlePackageType</key>
1818 <string>APPL</string>
1919 <key>CFBundleShortVersionString</key>
20 <string>3.3.58</string>
20 <string>3.3.59</string>
2121 <key>CFBundleSignature</key>
2222 <string>????</string>
2323 <key>CFBundleVersion</key>
24 <string>3.3.58</string>
24 <string>3.3.59</string>
2525 <key>NSHumanReadableCopyright</key>
2626 <string>Copyright 1999 - 2014 Tony Bybell, GNU General Public License.</string>
2727 <key>LSMinimumSystemVersion</key>
Binary diff not shown
0 .TH "GTKWAVE" "1" "3.3.29" "Anthony Bybell" "Simulation Wave Viewer"
0 .TH "GTKWAVE" "1" "3.3.59" "Anthony Bybell" "Simulation Wave Viewer"
11 .SH "NAME"
22 .LP
33 gtkwave \- Visualization tool for VCD, LXT, LXT2, VZT, FST, and GHW files
9393 Specifies delay in milliseconds between successive executions of the repscript. Default is 500.
9494 .TP
9595 \fB\-X\fR,\fB\-\-xid\fR <\fIXID\fP>
96 Specify XID of window for a GtkPlug to connect to. GTKWave does not directly render to a window but instead renders into a
96 Specify XID (in hexadecimal) of window for a GtkPlug to connect to. GTKWave does not directly render to a window but instead renders into a
9797 GtkPlug expecting a GtkSocket at the other end. Note that there are issues with accelerators working properly so menus are
9898 disabled in the componentized version of GTKWave when it functions as a plug-in.
9999 .TP
329329 if(GLOBALS->show_base) { *(pnt++)='"'; }
330330 *(pnt)=0x00; /* scan build : remove dead increment */
331331 }
332 else if((flags&TR_HEX)||((flags&(TR_DEC|TR_SIGNED))&&(nbits>64)))
332 else if((flags&TR_HEX)||((flags&(TR_DEC|TR_SIGNED))&&(nbits>64)&&(!(flags&TR_POPCNT))))
333333 {
334334 char *parse;
335335
989989 if(GLOBALS->show_base) { *(pnt++)='"'; }
990990 *(pnt)=0x00; /* scan build : remove dead increment */
991991 }
992 else if((flags&TR_HEX)||((flags&(TR_DEC|TR_SIGNED))&&(nbits>64)))
992 else if((flags&TR_HEX)||((flags&(TR_DEC|TR_SIGNED))&&(nbits>64)&&(!(flags&TR_POPCNT))))
993993 {
994994 char *parse;
995995
173173 }
174174 else
175175 {
176 sprintf(lpstrFilter, "%s%c%s%c%s%c%s%c", pattn, 0, pattn, 0, "All", 0, "*.*");
176 sprintf(lpstrFilter, "%s%c%s%c%s%c%s%c", pattn, 0, pattn, 0, "All", 0, "*.*", 0); /* cppcheck */
177177 ofn.nFilterIndex = 0;
178178 }
179179
523523 e->wkt = ghw_wkt_unknown;
524524 e->name = ghw_read_strid (h);
525525 if (ghw_read_uleb128 (h, (uint32_t *)&e->nbr) != 0)
526 return -1;
526 {
527 free(e); /* cppcheck */
528 return -1;
529 }
527530 e->lits = (const char **) calloc (1, e->nbr * sizeof (char *));
528531 if (h->flag_verbose > 1)
529532 printf ("enum %s:", e->name);
567570 int ix;
568571
569572 if (ghw_read_uleb128 (h, &ph->nbr_units) != 0)
570 return -1;
573 {
574 free(ph); /* cppcheck */
575 return -1;
576 }
571577 ph->units = calloc (ph->nbr_units, sizeof (struct ghw_unit));
572578 for (ix = 0; ix < ph->nbr_units; ix++)
573579 {
574580 ph->units[ix].name = ghw_read_strid (h);
575581 if (ghw_read_lsleb128 (h, &ph->units[ix].val) < 0)
576 return -1;
582 {
583 free(ph->units); /* missed by cppcheck */
584 free(ph); /* missed by cppcheck */
585 return -1;
586 }
577587 }
578588 }
579589 if (h->flag_verbose > 1)
605615 arr->name = ghw_read_strid (h);
606616 arr->el = ghw_read_typeid (h);
607617 if (ghw_read_uleb128 (h, (uint32_t *)&arr->nbr_dim) != 0)
608 return -1;
618 {
619 free(arr); /* cppcheck */
620 return -1;
621 }
609622 arr->dims = (union ghw_type **)
610623 calloc (arr->nbr_dim, sizeof (union ghw_type *));
611624 for (j = 0; j < arr->nbr_dim; j++)
649662 rec->kind = t;
650663 rec->name = ghw_read_strid (h);
651664 if (ghw_read_uleb128 (h, (uint32_t *)&rec->nbr_fields) != 0)
652 return -1;
665 {
666 free(rec); /* cppcheck */
667 return -1;
668 }
653669 rec->el = calloc
654670 (rec->nbr_fields, sizeof (struct ghw_record_element));
655671 nbr_el = 0;
2525 * FST_DYNAMIC_ALIAS_DISABLE : dynamic aliases are not processed
2626 * FST_DYNAMIC_ALIAS2_DISABLE : new encoding for dynamic aliases is not generated
2727 * FST_WRITEX_DISABLE : fast write I/O routines are disabled
28 * FST_DISABLE_DUFFS_DEVICE : only if indirect branches are incredibly bad on host arch
2829 *
2930 * possible enables:
3031 *
4849
4950 #ifdef FST_WRITER_PARALLEL
5051 #include <pthread.h>
52 #endif
53
54 #ifdef __MINGW32__
55 #include <windows.h>
5156 #endif
5257
5358 #if HAVE_ALLOCA_H
138143 #endif
139144 #endif
140145
141
142 /* the recoded "extra" values... */
146 /*
147 * the recoded "extra" values...
148 * note that FST_RCV_Q is currently unused and is for future expansion.
149 * its intended use is as another level of escape such that any arbitrary
150 * value can be stored as the value: { time_delta, 8 bits, FST_RCV_Q }.
151 * this is currently not implemented so that the branchless decode is:
152 * uint32_t shcnt = 2 << (vli & 1); tdelta = vli >> shcnt;
153 */
143154 #define FST_RCV_X (1 | (0<<1))
144155 #define FST_RCV_Z (1 | (1<<1))
145156 #define FST_RCV_H (1 | (2<<1))
147158 #define FST_RCV_W (1 | (4<<1))
148159 #define FST_RCV_L (1 | (5<<1))
149160 #define FST_RCV_D (1 | (6<<1))
161 #define FST_RCV_Q (1 | (7<<1))
150162
151163 #define FST_RCV_STR "xzhuwl-?"
152164 /* 01234567 */
160172 unlink(nam);
161173 return(fopen(nam, mode));
162174 }
175
176
177 /*
178 * system-specific temp file handling
179 */
180 #ifdef __MINGW32__
181
182 static FILE* tmpfile_open(char **nam)
183 {
184 char *fname = NULL;
185 TCHAR szTempFileName[MAX_PATH];
186 TCHAR lpTempPathBuffer[MAX_PATH];
187 DWORD dwRetVal = 0;
188 UINT uRetVal = 0;
189 FILE *fh = NULL;
190
191 dwRetVal = GetTempPath(MAX_PATH, lpTempPathBuffer);
192 if((dwRetVal > MAX_PATH) || (dwRetVal == 0))
193 {
194 fprintf(stderr, "GetTempPath() failed in "__FILE__" line %d, exiting.\n", __LINE__);
195 exit(255);
196 }
197 else
198 {
199 uRetVal = GetTempFileName(lpTempPathBuffer, TEXT("FSTW"), 0, szTempFileName);
200 if (uRetVal == 0)
201 {
202 fprintf(stderr, "GetTempFileName() failed in "__FILE__" line %d, exiting.\n", __LINE__);
203 exit(255);
204 }
205 else
206 {
207 fname = strdup(szTempFileName);
208 }
209 }
210
211 if(fname)
212 {
213 if(nam) { *nam = fname; }
214 fh = unlink_fopen("fname", "w+b");
215 }
216
217 return(fh);
218 }
219
220 #else
221
222 static FILE* tmpfile_open(char **nam)
223 {
224 FILE *f = tmpfile(); /* replace with mkstemp() + fopen(), etc if this is not good enough */
225 if(nam) { *nam = NULL; }
226 return(f);
227 }
228
229 #endif
230
231
232 static void tmpfile_close(FILE **f, char **nam)
233 {
234 if(f)
235 {
236 if(*f) { fclose(*f); *f = NULL; }
237 }
238
239 if(nam)
240 {
241 if(*nam)
242 {
243 unlink(*nam);
244 free(*nam);
245 *nam = NULL;
246 }
247 }
248 }
249
250 /*****************************************/
163251
164252
165253 /*
693781 uint32_t path_array_count;
694782
695783 unsigned fseek_failed : 1;
784
785 char *geom_handle_nam;
786 char *valpos_handle_nam;
787 char *curval_handle_nam;
788 char *tchn_handle_nam;
696789 };
697790
698791
10091102 xc->compress_hier = use_compressed_hier;
10101103 fstDetermineBreakSize(xc);
10111104
1012 if((!nam)||(!(xc->handle=unlink_fopen(nam, "w+b"))))
1105 if((!nam)||
1106 (!(xc->handle=unlink_fopen(nam, "w+b"))))
10131107 {
10141108 free(xc);
10151109 xc=NULL;
10231117 strcpy(hf + flen, ".hier");
10241118 xc->hier_handle = unlink_fopen(hf, "w+b");
10251119
1026 xc->geom_handle = tmpfile(); /* .geom */
1027 xc->valpos_handle = tmpfile(); /* .offs */
1028 xc->curval_handle = tmpfile(); /* .bits */
1029 xc->tchn_handle = tmpfile(); /* .tchn */
1120 xc->geom_handle = tmpfile_open(&xc->geom_handle_nam); /* .geom */
1121 xc->valpos_handle = tmpfile_open(&xc->valpos_handle_nam); /* .offs */
1122 xc->curval_handle = tmpfile_open(&xc->curval_handle_nam); /* .bits */
1123 xc->tchn_handle = tmpfile_open(&xc->tchn_handle_nam); /* .tchn */
10301124 xc->vchg_alloc_siz = xc->fst_break_size + xc->fst_break_add_size;
10311125 xc->vchg_mem = malloc(xc->vchg_alloc_siz);
10321126
1033 free(hf);
10341127 if(xc->hier_handle && xc->geom_handle && xc->valpos_handle && xc->curval_handle && xc->vchg_mem && xc->tchn_handle)
10351128 {
10361129 xc->filename = strdup(nam);
10461139 }
10471140 else
10481141 {
1049 if(xc->hier_handle) fclose(xc->hier_handle);
1050 if(xc->geom_handle) fclose(xc->geom_handle);
1051 if(xc->valpos_handle) fclose(xc->valpos_handle);
1052 if(xc->curval_handle) fclose(xc->curval_handle);
1053 if(xc->tchn_handle) fclose(xc->tchn_handle);
1142 fclose(xc->handle);
1143 if(xc->hier_handle) { fclose(xc->hier_handle); unlink(hf); }
1144 tmpfile_close(&xc->geom_handle, &xc->geom_handle_nam);
1145 tmpfile_close(&xc->valpos_handle, &xc->valpos_handle_nam);
1146 tmpfile_close(&xc->curval_handle, &xc->curval_handle_nam);
1147 tmpfile_close(&xc->tchn_handle, &xc->tchn_handle_nam);
10541148 free(xc->vchg_mem);
10551149 free(xc);
10561150 xc=NULL;
10571151 }
1152
1153 free(hf);
10581154 }
10591155
10601156 return(xc);
11601256 #endif
11611257 #endif
11621258
1163 if((!xc)||(xc->vchg_siz <= 1)||(xc->already_in_flush)) return;
1259 if((xc->vchg_siz <= 1)||(xc->already_in_flush)) return;
11641260 xc->already_in_flush = 1; /* should really do this with a semaphore */
11651261
11661262 xc->section_header_only = 0;
12901386 if(is_binary)
12911387 {
12921388 unsigned char acc = 0;
1389 #ifdef FST_DISABLE_DUFFS_DEVICE
1390 /* old algorithm */
12931391 int shift = 7 - ((vm4ip[1]-1) & 7);
12941392 for(idx=vm4ip[1]-1;idx>=0;idx--)
12951393 {
13021400 acc = 0;
13031401 }
13041402 }
1403 #else
1404 /* new algorithm */
1405 idx = ((vm4ip[1]+7) & ~7);
1406 switch(vm4ip[1] & 7)
1407 {
1408 case 0: do { acc = (pnt[idx+7-8] & 1) << 0;
1409 case 7: acc |= (pnt[idx+6-8] & 1) << 1;
1410 case 6: acc |= (pnt[idx+5-8] & 1) << 2;
1411 case 5: acc |= (pnt[idx+4-8] & 1) << 3;
1412 case 4: acc |= (pnt[idx+3-8] & 1) << 4;
1413 case 3: acc |= (pnt[idx+2-8] & 1) << 5;
1414 case 2: acc |= (pnt[idx+1-8] & 1) << 6;
1415 case 1: acc |= (pnt[idx+0-8] & 1) << 7;
1416 *(--scratchpnt) = acc;
1417 idx -= 8;
1418 } while(idx);
1419 }
1420 #endif
13051421
13061422 scratchpnt = fstCopyVarint32ToLeft(scratchpnt, (time_delta << 1));
13071423 }
16591775 #endif
16601776 free(xc->valpos_mem);
16611777 free(xc->vchg_mem);
1662 fclose(xc->tchn_handle);
1778 tmpfile_close(&xc->tchn_handle, &xc->tchn_handle_nam);
16631779 free(xc);
16641780
16651781 return(NULL);
17021818 }
17031819
17041820 xc->tchn_cnt = xc->tchn_idx = 0;
1705 xc->tchn_handle = tmpfile();
1821 xc->tchn_handle = tmpfile_open(&xc->tchn_handle_nam); /* child thread will deallocate file/name */
17061822 fstWriterFseeko(xc, xc->tchn_handle, 0, SEEK_SET);
17071823 fstFtruncate(fileno(xc->tchn_handle), 0);
17081824
19742090 fstWriterUint64(xc->handle, xc->secnum);
19752091 fflush(xc->handle);
19762092
1977 if(xc->tchn_handle) { fclose(xc->tchn_handle); xc->tchn_handle = NULL; }
2093 tmpfile_close(&xc->tchn_handle, &xc->tchn_handle_nam);
19782094 free(xc->vchg_mem); xc->vchg_mem = NULL;
1979 if(xc->curval_handle) { fclose(xc->curval_handle); xc->curval_handle = NULL; }
1980 if(xc->valpos_handle) { fclose(xc->valpos_handle); xc->valpos_handle = NULL; }
1981 if(xc->geom_handle) { fclose(xc->geom_handle); xc->geom_handle = NULL; }
2095 tmpfile_close(&xc->curval_handle, &xc->curval_handle_nam);
2096 tmpfile_close(&xc->valpos_handle, &xc->valpos_handle_nam);
2097 tmpfile_close(&xc->geom_handle, &xc->geom_handle_nam);
19822098 if(xc->hier_handle) { fclose(xc->hier_handle); xc->hier_handle = NULL; }
19832099 if(xc->handle)
19842100 {
29873103 int writex_fd;
29883104 unsigned char writex_buf[FST_WRITEX_MAX];
29893105 #endif
3106
3107 char *f_nam;
3108 char *fh_nam;
29903109 };
29913110
29923111
34643583 static int fstVcdIDForFwrite(char *buf, unsigned int value)
34653584 {
34663585 char *pnt = buf;
3467 unsigned int vmod;
34683586
34693587 /* zero is illegal for a value...it is assumed they start at one */
34703588 while (value)
35073625 sprintf(fnam, "%s.hier_%d_%p", xc->filename, getpid(), (void *)xc);
35083626 fstReaderFseeko(xc, xc->f, xc->hier_pos, SEEK_SET);
35093627 uclen = fstReaderUint64(xc->f);
3628 #ifndef __MINGW32__
35103629 fflush(xc->f);
3511
3630 #endif
35123631 if(htyp == FST_BL_HIER)
35133632 {
35143633 fstReaderFseeko(xc, xc->f, xc->hier_pos, SEEK_SET);
35153634 uclen = fstReaderUint64(xc->f);
3635 #ifndef __MINGW32__
35163636 fflush(xc->f);
3517
3637 #endif
35183638 zfd = dup(fileno(xc->f));
35193639 zhandle = gzdopen(zfd, "rb");
35203640 if(!zhandle)
35313651 fstReaderFseeko(xc, xc->f, xc->hier_pos - 8, SEEK_SET); /* get section len */
35323652 clen = fstReaderUint64(xc->f) - 16;
35333653 uclen = fstReaderUint64(xc->f);
3654 #ifndef __MINGW32__
35343655 fflush(xc->f);
3656 #endif
35353657 }
35363658
35373659 #ifndef __MINGW32__
35393661 if(!xc->fh)
35403662 #endif
35413663 {
3542 xc->fh = tmpfile();
3664 xc->fh = tmpfile_open(&xc->fh_nam);
35433665 free(fnam); fnam = NULL;
35443666 if(!xc->fh)
35453667 {
3668 tmpfile_close(&xc->fh, &xc->fh_nam);
35463669 free(mem);
35473670 return(0);
35483671 }
41304253 fcomp = fopen(hf, "w+b");
41314254 if(!fcomp)
41324255 {
4133 fcomp = tmpfile();
4256 fcomp = tmpfile_open(&xc->f_nam);
41344257 free(hf); hf = NULL;
4135 if(!fcomp) return(0);
4258 if(!fcomp) { tmpfile_close(&fcomp, &xc->f_nam); return(0); }
41364259 }
41374260
41384261 #if defined(FST_MACOSX)
41514274 #endif
41524275
41534276 fstReaderFseeko(xc, xc->f, 1+8+8, SEEK_SET);
4277 #ifndef __MINGW32__
41544278 fflush(xc->f);
4279 #endif
41554280
41564281 zfd = dup(fileno(xc->f));
41574282 zhandle = gzdopen(zfd, "rb");
45004625
45014626 if(xc->fh)
45024627 {
4503 fclose(xc->fh); xc->fh = NULL;
4628 tmpfile_close(&xc->fh, &xc->fh_nam);
45044629 }
45054630
45064631 if(xc->f)
45074632 {
4508 fclose(xc->f); xc->f = NULL;
4633 tmpfile_close(&xc->f, &xc->f_nam);
45094634 if(xc->filename_unpacked)
45104635 {
45114636 unlink(xc->filename_unpacked);
5454 static uint32_t var_direction_idx = 0;
5555 static unsigned char *var_direction = NULL;
5656
57
58 static void *realloc_2(void *ptr, size_t siz) /* cppcheck */
59 {
60 void *pnt = realloc(ptr, siz);
61 if(!pnt)
62 {
63 fprintf(stderr, "ERROR: Out of memory in realloc(), exiting!\n"); /* normally free(ptr) here */
64 exit(255);
65 }
66
67 return(pnt);
68 }
69
70
5771 /*********************************************************/
5872 /*** vvv extload component type name determination vvv ***/
5973 /*********************************************************/
379393 while(((*wbuf)[*len] != 1) && !feof(f))
380394 {
381395 /* fprintf(stderr, "overflow %d\n", (int)(*len)); */
382 *wbuf = realloc(*wbuf, (*len) * 2 + 1);
396 *wbuf = realloc_2(*wbuf, (*len) * 2 + 1);
383397 (*wbuf)[(*len) * 2] = 1;
384398
385399 fgets_rc = fgets(*wbuf + (*len), (*len) + 1, f);
506520 {
507521 printf("Could not open '%s', exiting.\n", vname);
508522 free(bin_fixbuff); bin_fixbuff = NULL;
523 free(vname); free(fstname);
509524 exit(255);
510525 }
511526
515530 {
516531 printf("Could not open '%s', exiting.\n", fstname);
517532 free(bin_fixbuff); bin_fixbuff = NULL;
533 free(vname); free(fstname);
534 fclose(f);
518535 exit(255);
519536 }
520537
13491366 if(node_len >= bin_fixbuff_len)
13501367 {
13511368 bin_fixbuff_len = node_len + 1;
1352 bin_fixbuff = realloc(bin_fixbuff, bin_fixbuff_len);
1369 bin_fixbuff = realloc_2(bin_fixbuff, bin_fixbuff_len);
13531370 }
13541371
13551372 memset(bin_fixbuff, buf[1] != '1' ? buf[1] : '0', delta);
13751392 if(node_len >= bin_fixbuff_len)
13761393 {
13771394 bin_fixbuff_len = node_len + 1;
1378 bin_fixbuff = realloc(bin_fixbuff, bin_fixbuff_len);
1395 bin_fixbuff = realloc_2(bin_fixbuff, bin_fixbuff_len);
13791396 }
13801397
13811398 memset(bin_fixbuff, buf[1] != '1' ? buf[1] : '0', delta);
14271444 if(p_len >= bin_fixbuff_len)
14281445 {
14291446 bin_fixbuff_len = p_len + 1;
1430 bin_fixbuff = realloc(bin_fixbuff, bin_fixbuff_len);
1447 bin_fixbuff = realloc_2(bin_fixbuff, bin_fixbuff_len);
14311448 }
14321449 pnt = bin_fixbuff;
14331450
14351435 vpa->lt = lt;
14361436 vpa->b = b;
14371437
1438 vzt_rd_pthread_create(lt, &b->pth, &b->pth_attr, vzt_rd_decompress_blk_pth_actual, vpa);
1438 vzt_rd_pthread_create(lt, &b->pth, &b->pth_attr, vzt_rd_decompress_blk_pth_actual, vpa); /* cppcheck misfires thinking vpa is not freed even though vzt_rd_decompress_blk_pth_actual() does it */
14391439 }
14401440
14411441 /*
139139 if((strlen(abs_path) == 0)||(!result))
140140 {
141141 status_text("Could not find filter process!\n");
142 pclose(stream); /* cppcheck */
142143 return;
143
144144 }
145145
146146 pclose(stream);
158158 if((strlen(abs_path) == 0)||(!result))
159159 {
160160 status_text("Could not find transaction filter process!\n");
161 pclose(stream); /* cppcheck */
161162 return;
162163
163164 }