[Asterisk-code-review] res_crypto: don't complain about directories (asterisk[20])

Philip Prindeville asteriskteam at digium.com
Thu Sep 15 00:23:08 CDT 2022


Philip Prindeville has uploaded this change for review. ( https://gerrit.asterisk.org/c/asterisk/+/19216 )


Change subject: res_crypto: don't complain about directories
......................................................................

res_crypto: don't complain about directories

ASTERISK-30226 #close

Change-Id: I5695fb0c9521f112f754b8362cff2a8f3eff05c5
---
M res/res_crypto.c
1 file changed, 14 insertions(+), 0 deletions(-)



  git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/16/19216/1

diff --git a/res/res_crypto.c b/res/res_crypto.c
index efcee7c..bc66318 100644
--- a/res/res_crypto.c
+++ b/res/res_crypto.c
@@ -786,6 +786,9 @@
 			if (!strcmp(ent->d_name, ".") || !strcmp(ent->d_name, "..")) {
 				continue;
 			}
+			if (ent->d_type == DT_DIR) {
+				continue;
+			}
 			if (ent->d_type != DT_REG) {
 				ast_log(LOG_WARNING, "Non-regular file '%s' in keys directory\n", ent->d_name);
 				continue;

-- 
To view, visit https://gerrit.asterisk.org/c/asterisk/+/19216
To unsubscribe, or for help writing mail filters, visit https://gerrit.asterisk.org/settings

Gerrit-Project: asterisk
Gerrit-Branch: 20
Gerrit-Change-Id: I5695fb0c9521f112f754b8362cff2a8f3eff05c5
Gerrit-Change-Number: 19216
Gerrit-PatchSet: 1
Gerrit-Owner: Philip Prindeville <philipp at redfish-solutions.com>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20220915/75561e8e/attachment.html>


More information about the asterisk-code-review mailing list