def reassembly(self, info):
BUFID = info.bufid  <EOL>DSN = info.dsn      <EOL>ACK = info.ack      <EOL>FIN = info.fin      <EOL>RST = info.rst      <EOL>SYN = info.syn      <EOL>if SYN and BUFID in self._buffer:<EOL><INDENT>self._dtgram += self.submit(self._buffer[BUFID], bufid=BUFID)<EOL>del self._buffer[BUFID]<EOL><DEDENT>if BUFID not in self._buffer:<EOL><INDENT>self._buffer[BUFID] = {<EOL>'<STR_LIT>': [Info(first=info.len, last=sys.maxsize)],<EOL>ACK: dict(<EOL>ind=[info.num],<EOL>isn=info.dsn,<EOL>len=info.len,<EOL>raw=info.payload,<EOL>),<EOL>}<EOL><DEDENT>else:<EOL><INDENT>if ACK not in self._buffer[BUFID]:<EOL><INDENT>self._buffer[BUFID][ACK] = dict(<EOL>ind=[info.num],<EOL>isn=info.dsn,<EOL>len=info.len,<EOL>raw=info.payload,<EOL>)<EOL><DEDENT>else:<EOL><INDENT>self._buffer[BUFID][ACK]['<STR_LIT>'].append(info.num)<EOL>ISN = self._buffer[BUFID][ACK]['<STR_LIT>']   <EOL>RAW = self._buffer[BUFID][ACK]['<STR_LIT>']   <EOL>if DSN >= ISN:  <EOL><INDENT>LEN = self._buffer[BUFID][ACK]['<STR_LIT>']<EOL>GAP = DSN - (ISN + LEN)     <EOL>if GAP >= <NUM_LIT:0>:    <EOL><INDENT>RAW += bytearray(GAP) + info.payload<EOL><DEDENT>else:           <EOL><INDENT>RAW[DSN-ISN:] = info.payload<EOL><DEDENT><DEDENT>else:           <EOL><INDENT>LEN = info.len<EOL>GAP = ISN - (DSN + LEN)     <EOL>self._buffer[BUFID][ACK]['<STR_LIT>'] = DSN<EOL>if GAP >= <NUM_LIT:0>:    <EOL><INDENT>RAW = info.payload + bytearray(GAP) + RAW<EOL><DEDENT>else:           <EOL><INDENT>RAW = info.payload + RAW[ISN-GAP:]<EOL><DEDENT><DEDENT>self._buffer[BUFID][ACK]['<STR_LIT>'] = RAW       <EOL>self._buffer[BUFID][ACK]['<STR_LIT>'] = len(RAW)  <EOL><DEDENT>HDL = self._buffer[BUFID]['<STR_LIT>']<EOL>for (index, hole) in enumerate(HDL):                            <EOL><INDENT>if info.first > hole.last:                                  <EOL><INDENT>continue<EOL><DEDENT>if info.last < hole.first:                                  <EOL><INDENT>continue<EOL><DEDENT>del HDL[index]                                              <EOL>if info.first > hole.first:                                 <EOL><INDENT>new_hole = Info(<EOL>first=hole.first,<EOL>last=info.first - <NUM_LIT:1>,<EOL>)<EOL>HDL.insert(index, new_hole)<EOL>index += <NUM_LIT:1><EOL><DEDENT>if info.last < hole.last and not FIN and not RST:           <EOL><INDENT>new_hole = Info(<EOL>first=info.last + <NUM_LIT:1>,<EOL>last=hole.last<EOL>)<EOL>HDL.insert(index, new_hole)<EOL><DEDENT>break                                                       <EOL><DEDENT>self._buffer[BUFID]['<STR_LIT>'] = HDL                                <EOL><DEDENT>if FIN or RST:<EOL><INDENT>self._dtgram += self.submit(self._buffer[BUFID], bufid=BUFID)<EOL>del self._buffer[BUFID]<EOL><DEDENT>
Reassembly procedure.

        Positional arguments:
            * info -- Info, info dict of packets to be reassembled