Attention is currently required from: osmith. pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-bsc-nat/+/27472 )
Change subject: Store BSCs ......................................................................
Patch Set 1: Code-Review-1
(3 comments)
File include/osmocom/bsc_nat/bsc_nat.h:
https://gerrit.osmocom.org/c/osmo-bsc-nat/+/27472/comment/5f13e937_5b915965 PS1, Line 43: struct llist_head bscs; /* list of struct bsc */ I think we usually would use bsc_list here, but not critical.
File src/osmo-bsc-nat/bsc_nat.c:
https://gerrit.osmocom.org/c/osmo-bsc-nat/+/27472/comment/b742658a_0cea154a PS1, Line 94: llist_for_each_entry(bsc, &bsc_nat->bscs, list) { This needs to be for_each_entry_safe AFAICT, otherwise you get a use-after-free.
File src/osmo-bsc-nat/bssap.c:
https://gerrit.osmocom.org/c/osmo-bsc-nat/+/27472/comment/976c3108_fa01707f PS1, Line 44: bsc = bsc_nat_bsc_add(g_bsc_nat, addr); could this return null?