lagopus icon indicating copy to clipboard operation
lagopus copied to clipboard

request switch description with a zero xid

Open eugene-che opened this issue 9 years ago • 2 comments

Hi,

There is a problem in channel_multipart_get from src/agent/channel.c. It does not check, if message in the i-th position of the channel storage is currently in use, and returns the first vacant position, when we search for OFPMP_DESC multipart requests with xid == 0, even if this message is at some further position. The following change fixes the issue:

  for (i = 0; i < CHANNEL_SIMULTANEOUS_MULTIPART_MAX; i++) {
    if (channel->multipart[i].used
        && channel->multipart[i].ofp_header.xid == xid_header->xid
        && channel->multipart[i].multipart_type == mtype) {
      /* found */
      break;
    }
  }

I am also bothered by multipart_free. Shouldn't it set m->used to 0, when it cleans up a multipart request?

eugene-che avatar May 31 '16 07:05 eugene-che

Hi @eugene-che,

Thank you for bug report. Your point is correct. We fix this issue in the next release.

We will show you a bug fix before the next release.

Thanks!

ynkjm avatar May 31 '16 08:05 ynkjm

Hi @eugene-che,

We have fixed this issues with the commit of 3661f72a59908469605ae642bba91d5d7685f34e Could you test on your environment?

Thanks!

ynkjm avatar Jul 12 '16 05:07 ynkjm