diff --git a/lib/src/phy/resampling/resample_arb.c b/lib/src/phy/resampling/resample_arb.c index 441e8c0dc..5cea28ed2 100644 --- a/lib/src/phy/resampling/resample_arb.c +++ b/lib/src/phy/resampling/resample_arb.c @@ -150,7 +150,7 @@ int srslte_resample_arb_compute(srslte_resample_arb_t *q, cf_t *input, cf_t *out res1 = srslte_resample_arb_dot_prod(filter_input, srslte_resample_arb_polyfilt[idx], SRSLTE_RESAMPLE_ARB_M); if(q->interpolate){ - res2 = srslte_resample_arb_dot_prod(filter_input, srslte_resample_arb_polyfilt[(idx%SRSLTE_RESAMPLE_ARB_N)+1], SRSLTE_RESAMPLE_ARB_M); + res2 = srslte_resample_arb_dot_prod(filter_input, srslte_resample_arb_polyfilt[(idx+1)%SRSLTE_RESAMPLE_ARB_N], SRSLTE_RESAMPLE_ARB_M); } if(idx == SRSLTE_RESAMPLE_ARB_N){ diff --git a/srsenb/src/mac/ue.cc b/srsenb/src/mac/ue.cc index d8ca3a8f2..3f3657594 100644 --- a/srsenb/src/mac/ue.cc +++ b/srsenb/src/mac/ue.cc @@ -279,6 +279,10 @@ bool ue::process_ce(srslte::sch_subh *subh) { case srslte::sch_subh::TRUNC_BSR: case srslte::sch_subh::SHORT_BSR: idx = subh->get_bsr(buff_size); + if(idx == -1){ + Error("Invalid Index Passed to lc groups\n"); + break; + } for (uint32_t i=0;iul_bsr(rnti, lc_groups[idx][i], buff_size[idx]); diff --git a/srsenb/test/upper/ip_test.cc b/srsenb/test/upper/ip_test.cc index 2b789cf27..190478f0d 100644 --- a/srsenb/test/upper/ip_test.cc +++ b/srsenb/test/upper/ip_test.cc @@ -642,6 +642,7 @@ int setup_if_addr(char *ip_addr) perror("ioctl"); return -1; } - + + close(sock); return(tun_fd); }