Ticket #2: 2_repstringfix.diff

File 2_repstringfix.diff, 1.2 KB (added by rlwalsh, 5 years ago)
  • cube.cmd

     
    55    º  Batch update of CONFIG.SYS-like files. CUBE modifies a Target ASCII  º
    66    º  file, given a set of commands in a Procedure file.                   º
    77    º                                                                       º
     8    º  2019-02-09 V3.0 RLW Correct endless REPSTRING loop                   º
    89    º  2019-02-09 V3.0 RLW Remove dead code                                 º
    910    º  2019-01-25 V2.9 SCS remove the bootdrive hack from YD                º
    1011    º                      newer rpm don't need that anymore, as we have    º
     
    577578        /* 2015-04-28 SHL avoid spurious uppercasing */
    578579        ospos = pos(Os,Tar)
    579580        if ospos > 0 then do                       /*     String is there     */
    580            s = left(was, ospos - 1)
    581            rest = substr(was, ospos + length(os))
     581           s = left(Target.w, ospos - 1)
     582           Target.w = substr(Target.w, ospos + length(os))
    582583           newtar = newtar || s || With            /*     replace occurrence  */
    583            Target.w = rest                         /*     next                */
    584584        end
    585585        else leave
    586586      end