refactoring brackets to allow for const values

This commit is contained in:
Paul Cruz 2017-06-15 16:27:38 -07:00
parent 0757eae6ff
commit acaefb531b

View File

@ -920,6 +920,7 @@ static int getFileInfo(fileInfo_t* info, const char* inFileName){
detectError = 1;
break;
}
{
int const ret = fseek(srcFile, ((long)headerSize)-((long)numBytesRead), SEEK_CUR);
if (ret != 0) {
DISPLAY("Error: could not move to end of frame header\n");
@ -927,6 +928,7 @@ static int getFileInfo(fileInfo_t* info, const char* inFileName){
break;
}
}
}
/* skip the rest of the blocks in the frame */
{
@ -1038,11 +1040,13 @@ static void displayInfo(const char* inFileName, fileInfo_t* info, int displayLev
int FIO_listFile(const char* inFileName, int displayLevel){
fileInfo_t info;
DISPLAYOUT("File: %s\n", inFileName);
{
int const error = getFileInfo(&info, inFileName);
if (error == 1) {
DISPLAY("An error occurred with getting file info\n");
return 1;
}
}
displayInfo(inFileName, &info, displayLevel);
return 0;
}