crashes because the empty state of the hold space is NULL but the empty
state of the pattern space is "".
case 'x': /* Exchange hold and pattern space */
{
char *tmp = pattern_space;
case 'x': /* Exchange hold and pattern space */
{
char *tmp = pattern_space;
- pattern_space = bbg.hold_space;
+ pattern_space = bbg.hold_space ? : xzalloc(1);
no_newline=0;
bbg.hold_space = tmp;
break;
no_newline=0;
bbg.hold_space = tmp;
break;