]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
test_librbd_fsx: use posix_memalign() to allocate aligned buffers
authorIlya Dryomov <ilya.dryomov@inktank.com>
Fri, 25 Apr 2014 09:36:53 +0000 (13:36 +0400)
committerIlya Dryomov <ilya.dryomov@inktank.com>
Wed, 7 May 2014 13:30:05 +0000 (17:30 +0400)
commit3513ba0ac450901bdeb852cb81f3df09a8466aec
treed11c551c5a464ea25220cda1f5007669e118f040
parent7df50ecd80d8ad34d1a051f0831b752bc4ee7191
test_librbd_fsx: use posix_memalign() to allocate aligned buffers

Use posix_memalign() to allocate good_buf and temp_buf, which must be
writebdy and readbdy aligned respectively.  Using round_ptr_up() the
way it is used makes fsx crash on free()s at the end of main(), because
the pointer returned by malloc() is overwritten by the aligned pointer.

Drop round_ptr_up() as it is no longer used.

Signed-off-by: Ilya Dryomov <ilya.dryomov@inktank.com>
src/test/librbd/fsx.c