[Dovecot-test] [dovecot/core] 90f5df39: lib-http: client: Fix panic occurring at connection failure.

noreply at dovecot.org noreply at dovecot.org
Mon Dec 10 13:30:06 EET 2018


  Branch: refs/heads/master
  Home:   https://github.com/dovecot/core
  Commit: 90f5df3993ded3d4a47bcb9587e5d003fbace7b3
      https://github.com/dovecot/core/commit/90f5df3993ded3d4a47bcb9587e5d003fbace7b3
  Author: Stephan Bosch <stephan.bosch at dovecot.fi>
  Date:   2018-12-07 (Fri, 07 Dec 2018)

  Changed paths:
    M src/lib-http/http-client-peer.c

  Log Message:
  -----------
  lib-http: client: Fix panic occurring at connection failure.

In http_client_peer_connection_failed_pool(), all linked queues are notified
about the connection failure through http_client_queue_connection_failure().
That function can internally link and unlink peers to the queue, including the
calling one. This means that the peer->queues array can be modified while it is
iterated in the array_foreach() loop. The problem is fixed by making a local
copy of the peer->queues array.

  Commit: a2ac8c0b4a3e39b638c979e4676138a27fb4ebfd
      https://github.com/dovecot/core/commit/a2ac8c0b4a3e39b638c979e4676138a27fb4ebfd
  Author: Stephan Bosch <stephan.bosch at dovecot.fi>
  Date:   2018-12-06 (Thu, 06 Dec 2018)

  Changed paths:
    M src/lib-http/http-client-queue.c
    M src/lib-http/test-http-client-errors.c

  Log Message:
  -----------
  lib-http: client: Fix handling of servers with several alternative IP addresses.

This also addresses an assert failure occurring with parallel clients:

Panic: file http-client-queue.c: line 518 (http_client_queue_connection_failure): assertion failed: (queue->cur_peer == peer)

  Patch: https://github.com/dovecot/core/compare/16db408725f5...90f5df3993de.patch


More information about the Dovecot-test mailing list