On Sat, May 02, 2020 at 10:14:15PM +0200, William Dauchy wrote:
> On Sat, May 02, 2020 at 09:52:36PM +0200, William Dauchy wrote:
> > +void srv_cleanup_connections(struct server *srv)
> > +{
> > + struct connection *conn;
> > + int did_remove;
> > + int i;
> > + int j;
> > +
> > + HA_SPIN_LOCK(OTHER_LOCK, &idle_conn_srv_lock);
> > + for (i = 0; i < global.nbthread; i++) {
> > + did_remove = 0;
> > + HA_SPIN_LOCK(OTHER_LOCK, &toremove_lock[i]);
> > + for (j = 0; j < srv->curr_idle_conns; j++) {
> > + conn = MT_LIST_POP(&srv->idle_conns[i], struct
> > connection *, list);
> > + if (!conn)
> > + conn = MT_LIST_POP(&srv->safe_conns[i],
> > + struct connection *, list);
> > + if (!conn)
> > + break;
>
> just realised I forgot:
> did_remove = 1;
>
> but will wait before sending a possible v2 with other feedbacks.
If that's the only change you have for a v2, don't bother, I already
integrated it in what I plan to push :)
Regards,
Olivier