Igalia/pflua

PF_VERBOSE is broken

kbara opened this issue · 1 comments

Code which works without PF_VERBOSE=1 crashes due to a change in pp.

% PF_VERBOSE=1 ../tools/pflua-compile "ip"
{ "if",
  { "<=",
    { "+",
      { "+",
        0,
        12 },
      2 },
    "len" },
  { "=",
    { "ntohs",
      { "[]",
        { "+",
          0,
          12 },
        2 } },
    2048 },
  { "fail" } }
{ "if",
  { ">=",
    "len",
    14 },
  { "=",
    { "[]",
      12,
      2 },
    8 },
  { "fail" } }
luajit: ../src/pf/utils.lua:119: unimplemented
stack traceback:
    [C]: in function 'error'
    ../src/pf/utils.lua:119: in function 'pp'
    ../src/pf/ssa.lua:200: in function 'optimize_ssa'
    ../src/pf/ssa.lua:300: in function 'convert_ssa'
    ../src/pf.lua:40: in function 'compile_filter'
    ../tools/pflua-compile:57: in main chunk
    [C]: at 0x00404bc0

Fixed in c0c854b