)]}'
{
  "commit": "8e76391096f12212985c401ee83a67990aa27a29",
  "tree": "e47eae62760bf28cf9108fc9816b9b403b4e2352",
  "parents": [
    "e179e87a1179e272a9bdabb0220b17d61d099ee3"
  ],
  "author": {
    "name": "Phil Sutter",
    "email": "phil@nwl.cc",
    "time": "Tue Feb 11 16:52:59 2020 +0100"
  },
  "committer": {
    "name": "Phil Sutter",
    "email": "phil@nwl.cc",
    "time": "Wed Feb 12 15:15:10 2020 +0100"
  },
  "message": "xtables-restore: fix for --noflush and empty lines\n\nLookahead buffer used for cache requirements estimate in restore\n--noflush separates individual lines with nul-chars. Two consecutive\nnul-chars are interpreted as end of buffer and remaining buffer content\nis skipped.\n\nSadly, reading an empty line (i.e., one containing a newline character\nonly) caused double nul-chars to appear in buffer as well, leading to\npremature stop when reading cached lines from buffer.\n\nTo fix that, make use of xtables_restore_parse_line() skipping empty\nlines without calling strtok() and just leave the newline character in\nplace. A more intuitive approach, namely skipping empty lines while\nbuffering, is deliberately not chosen as that would cause wrong values\nin \u0027line\u0027 variable.\n\nCloses: https://bugzilla.netfilter.org/show_bug.cgi?id\u003d1400\nFixes: 09cb517949e69 (\"xtables-restore: Improve performance of --noflush operation\")\nSigned-off-by: Phil Sutter \u003cphil@nwl.cc\u003e\nAcked-by: Arturo Borrero Gonzalez \u003carturo@netfilter.org\u003e\n",
  "tree_diff": [
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "bea1a690bb624d91250528b4efd0509e7ea308f4",
      "new_mode": 33261,
      "new_path": "iptables/tests/shell/testcases/ipt-restore/0011-noflush-empty-line_0"
    },
    {
      "type": "modify",
      "old_id": "63cc15cee96212cf7901205fc7ba0f611593077b",
      "old_mode": 33188,
      "old_path": "iptables/xtables-restore.c",
      "new_id": "fb2ac8b5c12a3c16a307693acde8fc55fb7a4d1b",
      "new_mode": 33188,
      "new_path": "iptables/xtables-restore.c"
    }
  ]
}
