travelping / vpp

5G User Plane Function (UPF) based on VPP

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

A problem was found in the GTP de-encap file.

CnaZhao opened this issue · comments

hello:
I found a problem in gtpu_decap.c. Should the order of the two sentences in the while loop be reversed? It should calculate the head length first, and then offset.

	      while ((u8 *)ext < end && ext->type != 0)
		    {
		      /* gtpu_ext_header_t is 4 bytes and the len is in units of 4 */
		      ext += ext->len * 4 / sizeof (*ext);
		      gtpu_hdr_len0 += ext->len * 4;
		    }

Right?

@CnaZhao thanks for the report and the fix!
The problem is fixed in c4ef531