Skip to content

Commit

Permalink
wo#4822 . seam must actually set the generated SPI
Browse files Browse the repository at this point in the history
  • Loading branch information
mcr committed Jul 4, 2017
1 parent 0ad6c6e commit 7b036cb
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions tests/unit/libpluto/seam_kernel.c
Expand Up @@ -9,12 +9,13 @@ ipsec_spi_t spis[4]={ 0x12345678,
0x56781234,
0x78123456};
static int spinext=0;
bool get_ipsec_spi(struct ipsec_proto_info *pi UNUSED
bool get_ipsec_spi(struct ipsec_proto_info *pi
, int proto UNUSED, struct state *st UNUSED
, bool tunnel UNUSED)
{
if(spinext == 4) spinext=0;
return htonl(spis[spinext++]);
pi->our_spi = htonl(spis[spinext++]);
return TRUE;
}

ipsec_spi_t get_my_cpi(struct state *st, bool tunnel)
Expand Down

0 comments on commit 7b036cb

Please sign in to comment.