mirror of
https://github.com/saitohirga/WSJT-X.git
synced 2024-11-24 21:28:41 -05:00
Squash compiler warnings
This commit is contained in:
parent
cee3c9796f
commit
e95451cdcc
36
getfile.cpp
36
getfile.cpp
@ -22,21 +22,21 @@
|
|||||||
|
|
||||||
void getfile(QString fname, int ntrperiod)
|
void getfile(QString fname, int ntrperiod)
|
||||||
{
|
{
|
||||||
struct WAVHDR {
|
// struct WAVHDR {
|
||||||
char ariff[4];
|
// char ariff[4];
|
||||||
int lenfile;
|
// int lenfile;
|
||||||
char awave[4];
|
// char awave[4];
|
||||||
char afmt[4];
|
// char afmt[4];
|
||||||
int lenfmt;
|
// int lenfmt;
|
||||||
short nfmt2;
|
// short nfmt2;
|
||||||
short nchan2;
|
// short nchan2;
|
||||||
int nsamrate;
|
// int nsamrate;
|
||||||
int nbytesec;
|
// int nbytesec;
|
||||||
short nbytesam2;
|
// short nbytesam2;
|
||||||
short nbitsam2;
|
// short nbitsam2;
|
||||||
char adata[4];
|
// char adata[4];
|
||||||
int ndata;
|
// int ndata;
|
||||||
} hdr;
|
// } hdr;
|
||||||
|
|
||||||
char name[512];
|
char name[512];
|
||||||
strncpy(name,fname.toLatin1(), sizeof (name) - 1);
|
strncpy(name,fname.toLatin1(), sizeof (name) - 1);
|
||||||
@ -93,10 +93,10 @@ void getfile(QString fname, int ntrperiod)
|
|||||||
if (!memcmp(desc.id,"data",sizeof desc.id)) break;
|
if (!memcmp(desc.id,"data",sizeof desc.id)) break;
|
||||||
} while (!fseek(fp,(desc.size + 1) / 2 * 2,SEEK_CUR));
|
} while (!fseek(fp,(desc.size + 1) / 2 * 2,SEEK_CUR));
|
||||||
|
|
||||||
// Read (and ignore) a 44-byte WAV header; then read data
|
// Read (and ignore) a 44-byte WAV header; then read data
|
||||||
// int n=fread(&hdr,1,44,fp);
|
// int n=fread(&hdr,1,44,fp);
|
||||||
int n=fread(dec_data.d2,2,npts,fp);
|
int n=fread(dec_data.d2,2,npts,fp);
|
||||||
if(hdr.nsamrate==11025) wav12_(dec_data.d2,dec_data.d2,&n,(short*)&fmt.nbitsam2);
|
if(fmt.nsamrate==11025) wav12_(dec_data.d2,dec_data.d2,&n,(short*)&fmt.nbitsam2);
|
||||||
fclose(fp);
|
fclose(fp);
|
||||||
dec_data.params.newdat=1;
|
dec_data.params.newdat=1;
|
||||||
dec_data.params.kin=n;
|
dec_data.params.kin=n;
|
||||||
|
Loading…
Reference in New Issue
Block a user