bob323
Feb 25th, 2002, 10:43 PM
am i using fscanf wrong, or using the wrong types? I can't get the precision required to capture these numbers, it always chops off numbers, here is what it is reading in:
207.23.53.200 1648.696 0.43913716114060686 1
LoadLine(){
FILE *input;
char cIp [12];
long float iRtt, iPackloss, iUtil;
int iPacketloss;
input = fopen("sampledata1.txt","r");
fscanf(input,"%s %lf %lf %i",&cIp, &iRtt, &iUtil, &iPackloss);
}
207.23.53.200 1648.696 0.43913716114060686 1
LoadLine(){
FILE *input;
char cIp [12];
long float iRtt, iPackloss, iUtil;
int iPacketloss;
input = fopen("sampledata1.txt","r");
fscanf(input,"%s %lf %lf %i",&cIp, &iRtt, &iUtil, &iPackloss);
}