Changeset 430


Ignore:
Timestamp:
16.08.2011 15:28:02 (8 years ago)
Author:
marcus
Message:

r224 | klaus | 2011-08-04 15:08:46 +0200 (Do, 04. Aug 2011) | 1 Zeile

bugfix for string overflow problem in SHM align command

Location:
SH_SHM/trunk/source
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • SH_SHM/trunk/source/motif/mfexec.c

    r119 r430  
    33 *      ======== 
    44 * 
    5  * $Revision: 82 $, $Date: 2009-04-30 09:16:57 +0200 (Do, 30 Apr 2009) $ 
     5 * $Revision: 224 $, $Date: 2011-08-04 15:08:46 +0200 (Do, 04. Aug 2011) $ 
    66 * 
    77 * execution of SH commands 
     
    691691        int        t;                    /* trace counter */ 
    692692        TSyStatus  locstat;              /* local status */ 
    693         char       str[BC_LINELTH+1];    /* scratch */ 
    694         char       trcstr[BC_LINELTH+1]; /* trace list string */ 
     693        char       str[cBcLongStrLth+1];    /* scratch */ 
     694        char       trcstr[cBcLongStrLth+1]; /* trace list string */ 
    695695        TSyBoolean create_beam;          /* create or delete beam */ 
    696696 
     
    721721                        mx_exec_sh( wm, ctrl, str ); 
    722722                } else { 
    723                         cl_calc_align_times( alignphase, BC_LINELTH-19, trcstr, status ); 
     723                        cl_calc_align_times( alignphase, cBcLongStrLth-19, trcstr, status ); 
    724724                        /* this is the textlength in the sprintf cmd ^ */ 
    725725                        if  (Severe(status))  return; 
  • SH_SHM/trunk/source/shmidlev.c

    r341 r430  
    358358{ 
    359359        /* local variables */ 
    360         char      str[BC_LINELTH+1];      /* parameter string */ 
    361  
    362         /* executable code */ 
    363  
    364         cp_getstr( par, pos, wdw, prompt, BC_LINELTH, str, status ); 
     360        char      str[cBcLongStrLth+1];      /* parameter string */ 
     361 
     362        /* executable code */ 
     363 
     364        cp_getstr( par, pos, wdw, prompt, cBcLongStrLth, str, status ); 
    365365        if  (*status == SHE_NOERROR)  { 
    366366                ml_trclist( str, trclist, listlth, status ); 
Note: See TracChangeset for help on using the changeset viewer.