Skip to content

Commit

Permalink
Issue identified, see #159 for specifics. Also see http://stackoverfl…
Browse files Browse the repository at this point in the history
  • Loading branch information
WardF committed Dec 23, 2015
1 parent 3e2a1cc commit d10688a
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 2 deletions.
6 changes: 5 additions & 1 deletion gdb.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
break cdf5_gh159_test.c:127
break cdf5_gh159_test.c:52
commands
continue
end
break cdf5_gh159_test.c:145
commands
break ncx_putn_uchar_double
break ncx.c:4845
Expand Down
20 changes: 19 additions & 1 deletion nc_test/cdf5_gh159_test.c
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,28 @@ main() {/* create cdf5_test */
/* variable ids */
int y3_id;
int y3d_id;

int i = 0;
int y3_dims[RANK_y3];
int y3d_dims[RANK_y3d];

/* Lets do a bit of other
testing here too. */
{
int xx = 0;
double *tp = (double*)malloc(sizeof(double)*3);
double *tph = tp;
unsigned char *xp = (unsigned char *)malloc(sizeof(unsigned char)*3);
unsigned char *xph = xp;
tp[0] = -2;
tp[1] = 255;
tp[2] = -1;

for(i = 0; i < 3; i++)
*xp++ = (unsigned)(signed char)*tp++;

xx = 1;
}

/* enter define mode */
stat = nc_create(FILENAME, NC_CLOBBER | NC_64BIT_DATA, &ncid);
check_err(stat,__LINE__,__FILE__);
Expand Down

0 comments on commit d10688a

Please sign in to comment.