Skip to content

Commit

Permalink
ims_ipsec_pcscf: fix gcc warning about misleading indention
Browse files Browse the repository at this point in the history
(cherry picked from commit 08e4510)
  • Loading branch information
henningw committed Oct 31, 2019
1 parent 543fbbf commit 50dcbdf
Showing 1 changed file with 16 additions and 15 deletions.
31 changes: 16 additions & 15 deletions src/modules/ims_ipsec_pcscf/spi_gen.c
Expand Up @@ -42,27 +42,28 @@ int init_spi_gen(uint32_t start_val, uint32_t range)
return 1;
}

if(UINT32_MAX - range < start_val)
if(UINT32_MAX - range < start_val) {
return 2;
}

if(spi_data){
return 3;
}
if(spi_data){
return 3;
}

spi_data = shm_malloc(sizeof(spi_generator_t));
if(spi_data == NULL){
return 4;
}
spi_data = shm_malloc(sizeof(spi_generator_t));
if(spi_data == NULL){
return 4;
}

if(pthread_mutex_init(&spi_data->spis_mut, NULL)){
shm_free(spi_data);
return 5;
}
if(pthread_mutex_init(&spi_data->spis_mut, NULL)){
shm_free(spi_data);
return 5;
}

spi_data->used_spis = create_list();
spi_data->used_spis = create_list();

spi_data->spi_val = spi_data->min_spi = start_val;
spi_data->max_spi = start_val + range;
spi_data->spi_val = spi_data->min_spi = start_val;
spi_data->max_spi = start_val + range;

return 0;
}
Expand Down

0 comments on commit 50dcbdf

Please sign in to comment.