allow old syntax of SET SUBSCRIBE_EVENTS_NP command (RHEL-29738)
Resolves: RHEL-29738
This commit is contained in:
parent
c2449868f3
commit
e484bad72a
26
linuxptp-subscribe.patch
Normal file
26
linuxptp-subscribe.patch
Normal file
@ -0,0 +1,26 @@
|
||||
commit b421a4c66ce636adff150dd1aa8eafa981c2693d
|
||||
Author: Miroslav Lichvar <mlichvar@redhat.com>
|
||||
Date: Wed Jan 3 14:45:51 2024 +0100
|
||||
|
||||
pmc: Allow missing values in SUBSCRIBE_EVENTS_NP command.
|
||||
|
||||
Don't require all supported notifications to be specified in the command
|
||||
for compatibility with older scripts.
|
||||
|
||||
Signed-off-by: Miroslav Lichvar <mlichvar@redhat.com>
|
||||
|
||||
diff --git a/pmc_common.c b/pmc_common.c
|
||||
index 62e34a6..b88cfc2 100644
|
||||
--- a/pmc_common.c
|
||||
+++ b/pmc_common.c
|
||||
@@ -310,8 +310,8 @@ static void do_set_action(struct pmc *pmc, int action, int index, char *str)
|
||||
onoff_port_state,
|
||||
onoff_time_status,
|
||||
onoff_parent_data_set);
|
||||
- if (cnt != 4) {
|
||||
- fprintf(stderr, "%s SET needs 4 values\n",
|
||||
+ if (cnt < 2) {
|
||||
+ fprintf(stderr, "%s SET needs at least 2 values\n",
|
||||
idtab[index].name);
|
||||
break;
|
||||
}
|
@ -29,6 +29,8 @@ Source22: linuxptp.te
|
||||
|
||||
# limit unicast message rate per address and grant duration
|
||||
Patch1: linuxptp-ucastrate.patch
|
||||
# allow old syntax of SET SUBSCRIBE_EVENTS_NP command
|
||||
Patch2: linuxptp-subscribe.patch
|
||||
|
||||
BuildRequires: gcc gcc-c++ make systemd
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user