Skip to content

Code sonar cleanup#7782

Merged
dgarske merged 4 commits intowolfSSL:masterfrom
bandi13:CodeSonarCleanup
Jul 30, 2024
Merged

Code sonar cleanup#7782
dgarske merged 4 commits intowolfSSL:masterfrom
bandi13:CodeSonarCleanup

Conversation

@bandi13
Copy link
Copy Markdown
Contributor

@bandi13 bandi13 commented Jul 23, 2024

No description provided.

Comment thread src/ssl_load.c Outdated
@bandi13 bandi13 force-pushed the CodeSonarCleanup branch 3 times, most recently from bf96af6 to f58c0cb Compare July 23, 2024 21:50
@bandi13 bandi13 force-pushed the CodeSonarCleanup branch from f58c0cb to 6175778 Compare July 23, 2024 21:59
Comment thread src/ssl_load.c Outdated
Comment thread src/ssl_load.c Outdated
@bandi13
Copy link
Copy Markdown
Contributor Author

bandi13 commented Jul 24, 2024

Retest this please

Comment thread wolfssl/wolfcrypt/types.h Outdated
WOLFSSL_API int wc_strncasecmp(const char *s1, const char *s2, size_t n);
#endif

WOLFSSL_API char* wc_strdup(const char *src, int memType);
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This should not be public... Please make WOLFSSL_LOCAL

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Done

Comment thread wolfcrypt/src/wc_port.c Outdated
}
#endif /* USE_WOLF_STRNCASECMP */

char* wc_strdup(const char *src, int memType) {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This should not be always exposed... It needs to be conditional based on #ifdef XGETENV or possibly another macro like USE_WOLF_STRDUP. I'd like to see this strdup function perfectly match the stdlib strdup API. Also consider fixing #define BUF_strdup strdup to use it...

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Done

@bandi13 bandi13 force-pushed the CodeSonarCleanup branch from bbeb246 to 87386f2 Compare July 26, 2024 16:13
@bandi13 bandi13 removed their assignment Jul 30, 2024
@bandi13 bandi13 requested a review from dgarske July 30, 2024 13:36
@dgarske dgarske merged commit 50d60bf into wolfSSL:master Jul 30, 2024
@bandi13 bandi13 deleted the CodeSonarCleanup branch August 5, 2024 21:53
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.

4 participants