Skip to content

Commit

Permalink
Merge pull request #181 from kipr/segfault
Browse files Browse the repository at this point in the history
Fixing servo/motor/transfer segfault
  • Loading branch information
bmcdorman authored Oct 25, 2022
2 parents 12caa3e + a44efc4 commit 3c879c2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions module/camera/dependencies/zlib/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,15 @@ set(ZLIB_COMMON_OPTIONS
if (CMAKE_CROSSCOMPILING)
get_property(ARCH GLOBAL PROPERTY arch)
ExternalProject_Add(dep_zlib
URL https://www.zlib.net/zlib-1.2.12.tar.gz
URL https://www.zlib.net/zlib-1.2.13.tar.gz
CMAKE_ARGS
-DCMAKE_TOOLCHAIN_FILE=${CMAKE_TOOLCHAIN_FILE}
${ZLIB_COMMON_OPTIONS}
INSTALL_COMMAND make install
)
else()
ExternalProject_Add(dep_zlib
URL https://www.zlib.net/zlib-1.2.12.tar.gz
URL https://www.zlib.net/zlib-1.2.13.tar.gz
CMAKE_ARGS
${ZLIB_COMMON_OPTIONS}
INSTALL_COMMAND make install
Expand All @@ -36,4 +36,4 @@ target_include_directories(zlib_wrapper INTERFACE ${ZLIB_INCLUDE_DIR})
# z
add_library(z_wrapper INTERFACE)
add_dependencies(z_wrapper zlib_wrapper)
target_link_libraries(z_wrapper INTERFACE zlib_wrapper z)
target_link_libraries(z_wrapper INTERFACE zlib_wrapper z)
2 changes: 1 addition & 1 deletion module/core/src/device/wombat/wombat_device.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ class WombatDevice : public kipr::core::Device
return false;
}

if (read_buffer[0] != 'J')
if (read_buffer && read_buffer[0] != 'J')
{
logger.error() << "DMA de-synchronized";
return false;
Expand Down

0 comments on commit 3c879c2

Please sign in to comment.