Skip to content

Commit

Permalink
merged ejh_bug_fix
Browse files Browse the repository at this point in the history
  • Loading branch information
edhartnett committed Mar 22, 2019
2 parents c45425d + 64496c8 commit 4e37d6e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 11 deletions.
13 changes: 3 additions & 10 deletions src/clib/pio_lists.c
Original file line number Diff line number Diff line change
Expand Up @@ -23,18 +23,12 @@ static file_desc_t *current_file = NULL;
*/
void pio_add_to_file_list(file_desc_t *file)
{
file_desc_t *cfile;

assert(file);

/* Get a pointer to the global list of files. */
cfile = pio_file_list;

/* Keep a global pointer to the current file. */
current_file = file;

/* If there is nothing in the list, then file will be the first
* entry. Otherwise, move to end of the list. */
/* Add file to list. */
HASH_ADD_INT(pio_file_list, pio_ncid, file);
}

Expand Down Expand Up @@ -279,10 +273,10 @@ int pio_delete_iodesc_from_list(int ioid)
io_desc_t *ciodesc;

ciodesc = pio_get_iodesc_from_id(ioid);
if(ciodesc)
if (ciodesc)
{
HASH_DEL(pio_iodesc_list, ciodesc);
if (current_iodesc = ciodesc)
if (current_iodesc == ciodesc)
current_iodesc = pio_iodesc_list;
free(ciodesc);
return PIO_NOERR;
Expand Down Expand Up @@ -367,7 +361,6 @@ int get_var_desc(int varid, var_desc_t **varlist, var_desc_t **var_desc)
int delete_var_desc(int varid, var_desc_t **varlist)
{
var_desc_t *v;
var_desc_t *prev = NULL;
int ret;

/* Check inputs. */
Expand Down
1 change: 0 additions & 1 deletion src/clib/pio_rearrange.c
Original file line number Diff line number Diff line change
Expand Up @@ -991,7 +991,6 @@ int rearrange_io2comp(iosystem_desc_t *ios, io_desc_t *iodesc, void *sbuf,
int niotasks;
int mpierr; /* Return code from MPI calls. */
int ret;
void *tmparray;

/* Check inputs. */
pioassert(ios && iodesc, "invalid input", __FILE__, __LINE__);
Expand Down

0 comments on commit 4e37d6e

Please sign in to comment.