{"name": "packetbuf_hdralloc", "code": "__int64 __fastcall packetbuf_hdralloc ( int @@a1@@ ) { if ( @@a1@@ > ( unsigned __int8 ) hdrptr || ( unsigned __int16 ) packetbuf_totlen ( ) + @@a1@@ > Number ) return Number L ; hdrptr -= @@a1@@ ; return Number L ; }", "source": [{"n": "a1", "t": {"T": 1, "n": "int", "s": 4}, "location": "r56"}]}
{"name": "create", "code": "__int64 create ( ) { __int64 v0 ; unsigned __int8 v1 ; __int64 v2 ; __int64 v3 ; unsigned int @@v4@@ ; __int64 v5 ; char @@s@@ [ Number ] ; char @@v8@@ ; char @@v9@@ ; char @@v10@@ ; char @@v11@@ ; char @@v12@@ ; unsigned __int8 @@v13@@ ; __int16 @@v14@@ ; char @@v15@@ [ Number ] ; __int16 @@v16@@ ; _BYTE @@v17@@ [ Number ] ; unsigned __int8 @@v18@@ ; memset ( @@s@@ , Number , Number ) ; if ( ! initialized ) { initialized = Number ; mac_dsn = random_rand ( ) ; } @@s@@ [ Number ] = Number ; @@s@@ [ Number ] = Number ; @@s@@ [ Number ] = packetbuf_attr ( Number L ) ; v0 = packetbuf_addr ( Number L ) ; if ( ( unsigned int ) rimeaddr_cmp ( v0 , ( __int64 ) & rimeaddr_null ) ) @@v8@@ = Number ; else @@v8@@ = packetbuf_attr ( Number L ) ; @@v9@@ = Number ; @@v11@@ = Number ; if ( ( unsigned __int16 ) packetbuf_attr ( Number L ) ) { @@v13@@ = packetbuf_attr ( Number L ) ; } else { v1 = mac_dsn ++ ; @@v13@@ = v1 ; packetbuf_set_attr ( Number L , v1 ) ; } @@v12@@ = Number ; @@v14@@ = Number ; v2 = packetbuf_addr ( Number L ) ; if ( ( unsigned int ) rimeaddr_cmp ( v2 , ( __int64 ) & rimeaddr_null ) ) { @@v10@@ = Number ; @@v15@@ [ Number ] = Number ; @@v15@@ [ Number ] = Number ; } else { v3 = packetbuf_addr ( Number L ) ; rimeaddr_copy ( ( __int64 ) @@v15@@ , v3 ) ; @@v10@@ = Number ; } @@v16@@ = Number ; rimeaddr_copy ( ( __int64 ) @@v17@@ , ( __int64 ) & rimeaddr_node_addr ) ; * ( _QWORD * ) & @@v17@@ [ Number ] = packetbuf_dataptr ( ) ; @@v17@@ [ Number ] = packetbuf_datalen ( ) ; @@v18@@ = frame802154_hdrlen ( @@s@@ ) ; if ( ! ( unsigned int ) packetbuf_hdralloc ( @@v18@@ ) ) return Number ; @@v4@@ = @@v18@@ ; v5 = packetbuf_hdrptr ( ) ; frame802154_create ( @@s@@ , v5 , @@v4@@ ) ; return @@v18@@ ; }", "source": [{"n": "v4", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "r32"}, {"n": "v18", "t": {"T": 1, "n": "unsigned __int8", "s": 1}, "location": "s17"}, {"n": "v17", "t": {"T": 2, "n": 57, "s": 1, "t": "_BYTE"}, "location": "s74"}, {"n": "v16", "t": {"T": 1, "n": "__int16", "s": 2}, "location": "s76"}, {"n": "v15", "t": {"T": 2, "n": 8, "s": 1, "t": "char"}, "location": "s84"}, {"n": "v14", "t": {"T": 1, "n": "__int16", "s": 2}, "location": "s86"}, {"n": "v13", "t": {"T": 1, "n": "unsigned __int8", "s": 1}, "location": "s88"}, {"n": "v12", "t": {"T": 1, "n": "char", "s": 1}, "location": "s89"}, {"n": "v11", "t": {"T": 1, "n": "char", "s": 1}, "location": "s90"}, {"n": "v10", "t": {"T": 1, "n": "char", "s": 1}, "location": "s91"}, {"n": "v9", "t": {"T": 1, "n": "char", "s": 1}, "location": "s92"}, {"n": "v8", "t": {"T": 1, "n": "char", "s": 1}, "location": "s93"}, {"n": "s", "t": {"T": 2, "n": 3, "s": 1, "t": "char"}, "location": "s96"}]} {"name": "packetbuf_totlen", "code": "__int64 packetbuf_totlen ( ) { int @@v0@@ ; @@v0@@ = ( unsigned __int8 ) packetbuf_hdrlen ( ) ; return @@v0@@ + ( unsigned int ) packetbuf_datalen ( ) ; }", "source": [{"n": "v0", "t": {"T": 1, "n": "int", "s": 4}, "location": "r32"}]} {"name": "queuebuf_to_packetbuf", "code": "__int64 __fastcall queuebuf_to_packetbuf ( unsigned __int64 @@a1@@ ) { __int64 result ; size_t @@v2@@ ; char * v3 ; __int64 @@v4@@ ; if ( memb_inmemb ( ( unsigned __int16 * ) bufmem , @@a1@@ ) ) { @@v4@@ = queuebuf_load_to_ram ( @@a1@@ ) ; packetbuf_copyfrom ( ( const void * ) ( @@v4@@ + Number ) , * ( _WORD * ) @@v4@@ ) ; result = packetbuf_attr_copyfrom ( ( const void * ) ( @@v4@@ + Number ) , ( __int64 * ) ( @@v4@@ + Number ) ) ; } else { result = memb_inmemb ( refbufmem , @@a1@@ ) ; if ( ( _DWORD ) result ) { packetbuf_clear ( ) ; packetbuf_copyfrom ( * ( const void * * ) ( @@a1@@ + Number ) , * ( _WORD * ) @@a1@@ ) ; packetbuf_hdralloc ( * ( unsigned __int8 * ) ( @@a1@@ + Number ) ) ; @@v2@@ = * ( unsigned __int8 * ) ( @@a1@@ + Number ) ; v3 = packetbuf_hdrptr ( ) ; result = ( __int64 ) memcpy ( v3 , ( const void * ) ( @@a1@@ + Number ) , @@v2@@ ) ; } } return result ; }", "source": [{"n": "v2", "t": {"T": 1, "n": "size_t", "s": 8}, "location": "r32"}, {"n": "a1", "t": {"T": 1, "n": "unsigned __int64", "s": 8}, "location": "r56"}, {"n": "v4", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s32"}]}