Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

op_que_events parameter parse

  • Loading branch information...
commit dc7603d53a1f59fe472fd6fb380be16564552e79 1 parent 16c4653
@nakagami authored
Showing with 11 additions and 1 deletion.
  1. +11 −1 misc/fbproxy.py
View
12 misc/fbproxy.py
@@ -1770,7 +1770,17 @@ def op_que_events(sock):
msg = sock.recv(bufsize)
up = xdrlib.Unpacker(msg)
print '\tdb_handle=', up.unpack_int()
- print '\tEventParameterBuffer<%s>' % (up.unpack_string())
+ prs = up.unpack_string() # param raw strings
+ param_strings = []
+ assert ord(prs[0]) == 1
+ i = 1
+ while i < len(prs):
+ ln = ord(prs[i])
+ s = prs[i+1:i+1+ln]
+ param_strings.append(s)
+ i += 5+ln
+
+ print '\tparam=', param_strings
print '\tast=', up.unpack_int()
print '\tevent_args=', up.unpack_int()
print '\tevent_rid=', up.unpack_int()
Please sign in to comment.
Something went wrong with that request. Please try again.