forked from sonic-net/sonic-buildimage
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix potential risks (sonic-net#2516)
- What I did Fix the following potential risks: Uncaught exceptions in /src/nvos-swss/orchagent/main.cpp and /src/nvos-swss/portsyncd/portsyncd.cpp Uninitialized scalar fields in /src/nvos-swss/orchagent/port.h Unchecked return value in /src/nvos-swss/orchagent/portsorch.cpp Pointer to local outside scope in /src/nvos-swss/orchagent/portsorch.cpp - How I did it Add "catch" to the uncaught exceptions Add initialization value to the uninitialized fields Add a check to the unchecked return value Delete an unnecessary comma - How I verified it Inspection and sanity tests Signed-off-by: Liran Artzi <[email protected]>
- Loading branch information
Showing
4 changed files
with
103 additions
and
73 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters