projects
/
ossec-hids.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
new upstream release (3.3.0); modify package compatibility for Stretch
[ossec-hids.git]
/
src
/
os_regex
/
os_regex_free_substrings.c
diff --git
a/src/os_regex/os_regex_free_substrings.c
b/src/os_regex/os_regex_free_substrings.c
old mode 100755
(executable)
new mode 100644
(file)
index
56e61ff
..
0c66bfc
--- a/
src/os_regex/os_regex_free_substrings.c
+++ b/
src/os_regex/os_regex_free_substrings.c
@@
-1,5
+1,3
@@
-/* $OSSEC, os_regex_free_substrings.c, v0.1, 2006/01/02, Daniel B. Cid$ */
-
/* Copyright (C) 2009 Trend Micro Inc.
* All right reserved.
*
/* Copyright (C) 2009 Trend Micro Inc.
* All right reserved.
*
@@
-9,7
+7,6
@@
* Foundation
*/
* Foundation
*/
-
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
@@
-18,18
+15,13
@@
#include "os_regex_internal.h"
#include "os_regex_internal.h"
-/** int OSRegex_FreeSubStrings(OSRegex *reg) v0.1
- * Release all the memory created to store the sub strings.
- * Returns void.
- */
+/* Release all the memory created to store the sub strings */
void OSRegex_FreeSubStrings(OSRegex *reg)
{
void OSRegex_FreeSubStrings(OSRegex *reg)
{
- /* Freeing the sub strings */
- if(reg->sub_strings)
- {
+ /* Free the sub strings */
+ if (reg->sub_strings) {
int i = 0;
int i = 0;
- while(reg->sub_strings[i])
- {
+ while (reg->sub_strings[i]) {
free(reg->sub_strings[i]);
reg->sub_strings[i] = NULL;
i++;
free(reg->sub_strings[i]);
reg->sub_strings[i] = NULL;
i++;
@@
-38,5
+30,3
@@
void OSRegex_FreeSubStrings(OSRegex *reg)
return;
}
return;
}
-
-/* EOF */