- char *ptr=hdr+20;
- long isgmtcnt=get_long(ptr);
- long isstdcnt=get_long(ptr);
- long leapcnt=get_long(ptr);
- long timecnt=get_long(ptr);
- long typecnt=get_long(ptr);
- long charcnt=get_long(ptr);
- int size=timecnt*5+typecnt*6+isgmtcnt+isstdcnt+leapcnt*8+charcnt;
- char buf[size];
- len=read(fd, buf, size);
+ char *ptr = hdr+20;
+ long isgmtcnt = get_long(ptr);
+ long isstdcnt = get_long(ptr);
+ long leapcnt = get_long(ptr);
+ long timecnt = get_long(ptr);
+ long typecnt = get_long(ptr);
+ long charcnt = get_long(ptr);
+ int size = timecnt*5+typecnt*6+isgmtcnt+isstdcnt+leapcnt*8+charcnt;
+ char *buf = new char[size];
+ len = read(fd, buf, size);