Commit 12a34f7
committed
Fix dangling pointer glusterd_ac_send_friend_remove_req()
In `glusterd-sm.c` we always use use gf_strdup when assigning
the peername, preventing a potential crash or invalid memory access
But glusterd_ac_send_friend_remove_req() was inadvertely
assigning directly, without using `strdup`, which caused a dangling
pointer problem which could potentially crash the application.
This commit fixes that problem by using the `strdup()` pattern
instead of the dangerous direct assignment.1 parent 895642d commit 12a34f7
1 file changed
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
479 | 479 | | |
480 | 480 | | |
481 | 481 | | |
482 | | - | |
| 482 | + | |
483 | 483 | | |
484 | 484 | | |
485 | 485 | | |
| |||
0 commit comments