- push @shistory, $inbuf;
- shift @shistory if @shistory > $maxshist;
+ if (length $inbuf >= $cols) {
+ $Text::Wrap::Columns = $cols;
+ push @shistory, wrap('',"\t", $inbuf);
+ } else {
+ push @shistory, $inbuf;
+ }
+ shift @shistory while @shistory > $maxshist;