Skip to content

Commit

Permalink
Check error code of posix_memalign().
Browse files Browse the repository at this point in the history
  • Loading branch information
xkszltl authored Jan 25, 2025
1 parent 1c1b1bd commit 8909829
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions test/gtest/ucs/arch/test_x86_64.cc
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,9 @@ class test_arch : public ucs::test {
*/
total_size = test_window_size + (2 * hole_size);

posix_memalign((void **)&test_window_src, align, total_size);
posix_memalign((void **)&test_window_dst, align, total_size);
posix_memalign((void **)&dup, align, total_size);
ASSERT_EQ(posix_memalign((void **)&test_window_src, align, total_size), 0);
ASSERT_EQ(posix_memalign((void **)&test_window_dst, align, total_size), 0);
ASSERT_EQ(posix_memalign((void **)&dup, align, total_size), 0);

src = test_window_src + hole_size;
dst = test_window_dst + hole_size;
Expand Down

0 comments on commit 8909829

Please sign in to comment.