1. 02 Feb, 2019 1 commit
    • Wez's avatar
      [Fuchsia] Make our FIDL error-handlers more consistent. · 08e32230
      Wez authored
      Update the functions we register as FIDL error handlers to use :
      - ZX_LOG(FATAL, status) where we never expect to lose connectivity,
        e.g. for connections to system services such as the Netstack. We
        typically follow these with an indication of what disconnected, e.g:
          ZX_LOG(FATAL, status) << " Netstack disconnected.";
      - ZX_LOG_IF(FATAL, status != ZX_ERR_PEER_CLOSED, status) where we are
        providing service to a single peer that may disconnect from us at any
        time, where other status values are unexpected.
      - ZX_LOG(ERROR, status) where we never expect to lose connectivity, but
        are serving multiple peers, so must not simply crash the process.
      - ZX_LOG_IF(ERROR, status != ZX_ERR_PEER_CLOSED, status) where we are
        providing service to multiple peers that we expect may disconnect, to
        verify that they do so gracefully.
      
      We also update FIDL error handlers in some test suites:
      - EXPECT_EQ(status, ZX_ERR_PEER_CLOSED) where the test actively expects
        that the FIDL channel will be disconnected gracefully.
      - ZX_LOG(ERROR, status) where the test does not expect FIDL errors.
      
      Bug: 927400
      Change-Id: I10fef90778e58f2aedadb806f857da00aace96aa
      Reviewed-on: https://chromium-review.googlesource.com/c/1448796
      Auto-Submit: Wez <wez@chromium.org>
      Reviewed-by: default avatarSergey Ulanov <sergeyu@chromium.org>
      Commit-Queue: Wez <wez@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#628524}
      08e32230
  2. 01 Feb, 2019 39 commits