Hi Marcel > Hi Mohamed, > > > diff --git a/gweb/gweb.c b/gweb/gweb.c > > index a348cdd..2533a3a 100644 > > --- a/gweb/gweb.c > > +++ b/gweb/gweb.c > > @@ -402,7 +402,8 @@ static gboolean process_send_buffer(struct web_session > > *session) > > if (status != G_IO_STATUS_NORMAL && status != G_IO_STATUS_AGAIN) > > return FALSE; > > > > - g_string_erase(buf, 0, bytes_written); > > + if (status == G_IO_STATUS_NORMAL) > > + g_string_erase(buf, 0, bytes_written); > > > > return TRUE; > > } > > I was going to apply this patch, but what is actually wrong with this > one? So bytes_writen return the actual written bytes and it can happen > that we have have written some. The number bytes we have written should > be erased Independent from the return value, right? > I thought about it but since we never check that before i thought it will never happen, but since you brought it up I can resend the patch with checking bytes_writen. Thanks Mohamed
_______________________________________________ connman mailing list [email protected] http://lists.connman.net/listinfo/connman
