Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix rdb_child_exit_pipe incorrect close call #801

Merged

Conversation

enjoy-binbin
Copy link
Member

server.rdb_child_exit_pipe is init in !dual_channel block,
so the call here would be close(-1) in !dual_channel way.

It will also generate a warning in valgrind:
Warning: invalid file descriptor -1 in syscall close()

Introduced in #60.

server.rdb_child_exit_pipe is init in !dual_channel block,
so the call here would be close(-1) in !dual_channel way.

It will also generate a warning in valgrind:
Warning: invalid file descriptor -1 in syscall close()

Introduced in valkey-io#60.

Signed-off-by: Binbin <binloveplay1314@qq.com>
@enjoy-binbin
Copy link
Member Author

@naglera please also take a look.

Copy link

codecov bot commented Jul 18, 2024

Codecov Report

Attention: Patch coverage is 50.00000% with 1 line in your changes missing coverage. Please review.

Project coverage is 70.43%. Comparing base (c584371) to head (20117e7).

Additional details and impacted files
@@             Coverage Diff              @@
##           unstable     #801      +/-   ##
============================================
- Coverage     70.44%   70.43%   -0.02%     
============================================
  Files           112      112              
  Lines         61135    61135              
============================================
- Hits          43066    43058       -8     
- Misses        18069    18077       +8     
Files Coverage Δ
src/rdb.c 76.13% <50.00%> (+0.14%) ⬆️

... and 13 files with indirect coverage changes

Copy link
Member

@PingXie PingXie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @enjoy-binbin!

@PingXie PingXie merged commit 36e81d9 into valkey-io:unstable Jul 18, 2024
20 checks passed
@enjoy-binbin enjoy-binbin deleted the fix_close_rdb_child_exit_pipe branch July 18, 2024 06:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants