Re: [ovs-dev] [PATCH v3 4/8] sflow: Use uint32_t instead of time_t for tick handling in the poller.
On 5/30/24 09:28, Eelco Chaudron wrote: > > > On 29 May 2024, at 12:53, Eelco Chaudron wrote: > >> The sFlow library uses a uint32_t to configure timeout ticks, but >> stores this value as a time_t. Although this doesn't cause functional >> issues, it wastes space and confuses Coverity, potentially indicating >> a Y2K38 problem when storing uint32_t values in time_t. This patch >> updates the internal data structures to use uint32_t variables. >> >> Fixes: c72e245a0e2c ("Add InMon's sFlow Agent library to the build system.") >> Acked-by: Mike Pattrick >> Signed-off-by: Eelco Chaudron >> --- >> lib/sflow_api.h | 4 ++-- >> 1 file changed, 2 insertions(+), 2 deletions(-) >> >> diff --git a/lib/sflow_api.h b/lib/sflow_api.h >> index eb23e2acd..f4bfa5ead 100644 >> --- a/lib/sflow_api.h >> +++ b/lib/sflow_api.h >> @@ -148,7 +148,7 @@ typedef struct _SFLPoller { >> /* MIB fields */ >> SFLDataSource_instance dsi; >> u_int32_t sFlowCpReceiver; >> -time_t sFlowCpInterval; >> +u_int32_t sFlowCpInterval; >> /* public fields */ >> struct _SFLAgent *agent; /* pointer to my agent */ >> void *magic; /* ptr to pass back in getCountersFn() */ >> @@ -156,7 +156,7 @@ typedef struct _SFLPoller { >> u_int32_t bridgePort; /* port number local to bridge */ >> /* private fields */ >> SFLReceiver *myReceiver; >> -time_t countersCountdown; >> +u_int32_t countersCountdown; >> u_int32_t countersSampleSeqNo; >> } SFLPoller; >> >> -- >> 2.44.0 > > Recheck-request: github-robot > GitHub claims that the issue is fixed. Let's try again. Recheck-request: github-robot ___ dev mailing list d...@openvswitch.org https://mail.openvswitch.org/mailman/listinfo/ovs-dev
Re: [ovs-dev] [PATCH v3 4/8] sflow: Use uint32_t instead of time_t for tick handling in the poller.
On 29 May 2024, at 12:53, Eelco Chaudron wrote: > The sFlow library uses a uint32_t to configure timeout ticks, but > stores this value as a time_t. Although this doesn't cause functional > issues, it wastes space and confuses Coverity, potentially indicating > a Y2K38 problem when storing uint32_t values in time_t. This patch > updates the internal data structures to use uint32_t variables. > > Fixes: c72e245a0e2c ("Add InMon's sFlow Agent library to the build system.") > Acked-by: Mike Pattrick > Signed-off-by: Eelco Chaudron > --- > lib/sflow_api.h | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/lib/sflow_api.h b/lib/sflow_api.h > index eb23e2acd..f4bfa5ead 100644 > --- a/lib/sflow_api.h > +++ b/lib/sflow_api.h > @@ -148,7 +148,7 @@ typedef struct _SFLPoller { > /* MIB fields */ > SFLDataSource_instance dsi; > u_int32_t sFlowCpReceiver; > -time_t sFlowCpInterval; > +u_int32_t sFlowCpInterval; > /* public fields */ > struct _SFLAgent *agent; /* pointer to my agent */ > void *magic; /* ptr to pass back in getCountersFn() */ > @@ -156,7 +156,7 @@ typedef struct _SFLPoller { > u_int32_t bridgePort; /* port number local to bridge */ > /* private fields */ > SFLReceiver *myReceiver; > -time_t countersCountdown; > +u_int32_t countersCountdown; > u_int32_t countersSampleSeqNo; > } SFLPoller; > > -- > 2.44.0 Recheck-request: github-robot ___ dev mailing list d...@openvswitch.org https://mail.openvswitch.org/mailman/listinfo/ovs-dev
Re: [ovs-dev] [PATCH v3 4/8] sflow: Use uint32_t instead of time_t for tick handling in the poller.
On 5/29/24 12:53, Eelco Chaudron wrote: > The sFlow library uses a uint32_t to configure timeout ticks, but > stores this value as a time_t. Although this doesn't cause functional > issues, it wastes space and confuses Coverity, potentially indicating > a Y2K38 problem when storing uint32_t values in time_t. This patch > updates the internal data structures to use uint32_t variables. > > Fixes: c72e245a0e2c ("Add InMon's sFlow Agent library to the build system.") > Acked-by: Mike Pattrick > Signed-off-by: Eelco Chaudron > --- Recheck-request: github-robot ___ dev mailing list d...@openvswitch.org https://mail.openvswitch.org/mailman/listinfo/ovs-dev
[ovs-dev] [PATCH v3 4/8] sflow: Use uint32_t instead of time_t for tick handling in the poller.
The sFlow library uses a uint32_t to configure timeout ticks, but stores this value as a time_t. Although this doesn't cause functional issues, it wastes space and confuses Coverity, potentially indicating a Y2K38 problem when storing uint32_t values in time_t. This patch updates the internal data structures to use uint32_t variables. Fixes: c72e245a0e2c ("Add InMon's sFlow Agent library to the build system.") Acked-by: Mike Pattrick Signed-off-by: Eelco Chaudron --- lib/sflow_api.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/sflow_api.h b/lib/sflow_api.h index eb23e2acd..f4bfa5ead 100644 --- a/lib/sflow_api.h +++ b/lib/sflow_api.h @@ -148,7 +148,7 @@ typedef struct _SFLPoller { /* MIB fields */ SFLDataSource_instance dsi; u_int32_t sFlowCpReceiver; -time_t sFlowCpInterval; +u_int32_t sFlowCpInterval; /* public fields */ struct _SFLAgent *agent; /* pointer to my agent */ void *magic; /* ptr to pass back in getCountersFn() */ @@ -156,7 +156,7 @@ typedef struct _SFLPoller { u_int32_t bridgePort; /* port number local to bridge */ /* private fields */ SFLReceiver *myReceiver; -time_t countersCountdown; +u_int32_t countersCountdown; u_int32_t countersSampleSeqNo; } SFLPoller; -- 2.44.0 ___ dev mailing list d...@openvswitch.org https://mail.openvswitch.org/mailman/listinfo/ovs-dev