redis-cli --rdb: fix broken fsync/ftruncate for stdout (#9135)
A change in redis 6.2 caused redis-cli --rdb that's directed to stdout to fail because fsync fails. This commit avoids doing ftruncate (fails with a warning) and fsync (fails with an error) when the output file is `-`, and adds the missing documentation that `-` means stdout. Co-authored-by:Oran Agra <oran@redislabs.com> Co-authored-by:
Wang Yuan <wangyuancode@163.com> (cherry picked from commit 74fe15b3)
Please register or sign in to comment