)]}'
{
  "commit": "107fb101805cc2b8eedfe4ca2ffbc6e578c2d12c",
  "tree": "d88fbd64da602e9d8e5ab6e35c8877c34f9253ba",
  "parents": [
    "dee6b63a95577214d94d4b70ff6f77a55135511b"
  ],
  "author": {
    "name": "Maxim Dounin",
    "email": "mdounin@mdounin.ru",
    "time": "Thu Oct 17 16:02:24 2019 +0300"
  },
  "committer": {
    "name": "Maxim Dounin",
    "email": "mdounin@mdounin.ru",
    "time": "Thu Oct 17 16:02:24 2019 +0300"
  },
  "message": "SSL: available bytes handling (ticket #1431).\n\nAdded code to track number of bytes available in the socket.\nThis makes it possible to avoid looping for a long time while\nworking with fast enough peer when data are added to the socket buffer\nfaster than we are able to read and process data.\n\nWhen kernel does not provide number of bytes available, it is\nretrieved using ioctl(FIONREAD) as long as a buffer is filled by\nSSL_read().\n\nIt is assumed that number of bytes returned by SSL_read() is close\nto the number of bytes read from the socket, as we do not use\nSSL compression.  But even if it is not true for some reason, this\nis not important, as we post an additional reading event anyway.\n\nNote that data can be buffered at SSL layer, and it is not possible\nto simply stop reading at some point and wait till the event will\nbe reported by the kernel again.  This can be only done when there\nare no data in SSL buffers, and there is no good way to find out if\nit\u0027s the case.\n\nInstead of trying to figure out if SSL buffers are empty, this patch\nintroduces events posted for the next event loop iteration - such\nevents will be processed only on the next event loop iteration,\nafter going into the kernel and retrieving additional events.  This\nseems to be simple and reliable approach.\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "69c55d7a0602670cf94bf2f6d9ea5ee75ca9a599",
      "old_mode": 33188,
      "old_path": "src/event/ngx_event.c",
      "new_id": "6e19f311b61c02eb8e344a8cdb30ce9339d79e90",
      "new_mode": 33188,
      "new_path": "src/event/ngx_event.c"
    },
    {
      "type": "modify",
      "old_id": "4e3eb391c8b4d064ba4741e8df221b40520b7e45",
      "old_mode": 33188,
      "old_path": "src/event/ngx_event_openssl.c",
      "new_id": "e9431b2d6a19148fe3ef4496662f387c234d4598",
      "new_mode": 33188,
      "new_path": "src/event/ngx_event_openssl.c"
    },
    {
      "type": "modify",
      "old_id": "61da0c5db6f2114adf863b48597bd0a7e0d8f509",
      "old_mode": 33188,
      "old_path": "src/event/ngx_event_openssl.h",
      "new_id": "71df9004526dbc8d800258ffb018fc113ea4d670",
      "new_mode": 33188,
      "new_path": "src/event/ngx_event_openssl.h"
    },
    {
      "type": "modify",
      "old_id": "d851f3d14fc3c5b95720592a3efcf549f1081b1b",
      "old_mode": 33188,
      "old_path": "src/event/ngx_event_posted.c",
      "new_id": "fd0b411c4c3da7ee1078aa4292fcc26733467e2c",
      "new_mode": 33188,
      "new_path": "src/event/ngx_event_posted.c"
    },
    {
      "type": "modify",
      "old_id": "145d30feac760af4d56e4b7fd21e93c643c4557f",
      "old_mode": 33188,
      "old_path": "src/event/ngx_event_posted.h",
      "new_id": "bac5b35552642117f1dee1a760927476ecabdc1a",
      "new_mode": 33188,
      "new_path": "src/event/ngx_event_posted.h"
    }
  ]
}
