fix(os): win compile error
This commit is contained in:
parent
d44f4137b2
commit
bf44937dca
|
@ -226,10 +226,10 @@ endif(${BUILD_WITH_NURAFT})
|
||||||
if(${BUILD_PTHREAD})
|
if(${BUILD_PTHREAD})
|
||||||
set(CMAKE_BUILD_TYPE release)
|
set(CMAKE_BUILD_TYPE release)
|
||||||
add_definitions(-DPTW32_STATIC_LIB)
|
add_definitions(-DPTW32_STATIC_LIB)
|
||||||
add_subdirectory(pthread)
|
add_subdirectory(pthread EXCLUDE_FROM_ALL)
|
||||||
set_target_properties(libpthreadVC3 PROPERTIES OUTPUT_NAME pthread)
|
set_target_properties(libpthreadVC3 PROPERTIES OUTPUT_NAME pthread)
|
||||||
add_library(pthread STATIC IMPORTED GLOBAL)
|
add_library(pthread INTERFACE)
|
||||||
SET_PROPERTY(TARGET pthread PROPERTY IMPORTED_LOCATION ${LIBRARY_OUTPUT_PATH}/pthread.lib)
|
target_link_libraries(pthread INTERFACE libpthreadVC3)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# iconv
|
# iconv
|
||||||
|
|
|
@ -361,7 +361,7 @@ int32_t indexConvertDataToStr(void* src, int8_t type, void** dst) {
|
||||||
tlen = taosEncodeBinary(NULL, varDataVal(src), varDataLen(src));
|
tlen = taosEncodeBinary(NULL, varDataVal(src), varDataLen(src));
|
||||||
*dst = taosMemoryCalloc(1, tlen + 1);
|
*dst = taosMemoryCalloc(1, tlen + 1);
|
||||||
tlen = taosEncodeBinary(dst, varDataVal(src), varDataLen(src));
|
tlen = taosEncodeBinary(dst, varDataVal(src), varDataLen(src));
|
||||||
*dst = *dst - tlen;
|
*dst = (char*) * dst - tlen;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case TSDB_DATA_TYPE_VARCHAR: { // TSDB_DATA_TYPE_BINARY
|
case TSDB_DATA_TYPE_VARCHAR: { // TSDB_DATA_TYPE_BINARY
|
||||||
|
|
Loading…
Reference in New Issue