kopia lustrzana https://github.com/AlexandreRouma/SDRPlusPlus
Merge pull request #85 from nonoo/master
Fix file source rewind and read after it is finishedpull/96/head
commit
b72246d769
|
@ -12,6 +12,8 @@ file(GLOB_RECURSE SRC "src/*.cpp" "src/*.c")
|
|||
include_directories("src/")
|
||||
include_directories("src/libcorrect/")
|
||||
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -march=native")
|
||||
|
||||
add_library(falcon9_decoder SHARED ${SRC})
|
||||
target_link_libraries(falcon9_decoder PRIVATE sdrpp_core)
|
||||
set_target_properties(falcon9_decoder PROPERTIES PREFIX "")
|
||||
|
|
|
@ -43,6 +43,7 @@ public:
|
|||
file.read(_data, size);
|
||||
int read = file.gcount();
|
||||
if (read < size) {
|
||||
file.clear();
|
||||
file.seekg(sizeof(WavHeader_t));
|
||||
file.read(&_data[read], size - read);
|
||||
}
|
||||
|
|
Ładowanie…
Reference in New Issue