From: Nikita Kalyazin Date: Fri, 1 Nov 2013 07:36:49 +0000 (+0400) Subject: [FIX] read and write for non regular/socket fd X-Git-Tag: Tizen_SDK_2.3~123 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f0fd1db1329c354a7bef990985e01ff45fbb1d3d;p=platform%2Fcore%2Fsystem%2Fswap-probe.git [FIX] read and write for non regular/socket fd This concerns the situation of invalid fd. fstat also returns false (regular/socket fd) in such cases. Change-Id: I3af55ad524ce2e0d19b7e298a224e736af3a30bc Signed-off-by: Nikita Kalyazin --- diff --git a/probe_file/da_io.h b/probe_file/da_io.h index c91063c..bd10f0c 100755 --- a/probe_file/da_io.h +++ b/probe_file/da_io.h @@ -174,8 +174,8 @@ static inline bool stat_regular_or_socket_p(struct stat *buf) PACK_COMMON_END(0, 0, blockresult); \ PACK_RESOURCE(0, FD, APITYPE, _filesize, _filepath); \ FLUSH_LOCAL_BUF(); \ - PRE_PROBEBLOCK_END(); \ - } + } \ + PRE_PROBEBLOCK_END(); #define AFTER_ORIGINAL_START_END_FD(API_ID, RVAL, SIZE, FD, APITYPE, INPUTFORMAT, ...) \