Branch: Tag:

2001-06-21

2001-06-21 01:21:50 by Per Hedbor <ph@opera.com>

Fix for get() with empty buffer

Rev: src/builtin.cmod:1.21

1:   /* -*- c -*- -  * $Id: builtin.cmod,v 1.20 2001/06/21 00:25:15 per Exp $ +  * $Id: builtin.cmod,v 1.21 2001/06/21 01:21:50 per Exp $    */      #include "global.h"
544:    */    {    struct Buffer_struct *str = THIS; +  if( str->str.s ) +  {    struct pike_string *s = finish_string_builder( &str->str );    str->str.malloced = 0;    str->str.s = 0;    RETURN s;    } -  +  pop_n_elems(args); +  push_text(""); +  }       INIT    {