projects
/
apps
/
madmutt.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
From: Konstantin Sobolev <kos@supportwizard.com>
[apps/madmutt.git]
/
lib
/
rx.c
diff --git
a/lib/rx.c
b/lib/rx.c
index
e7c4f3c
..
c0f6982
100644
(file)
--- a/
lib/rx.c
+++ b/
lib/rx.c
@@
-14,10
+14,10
@@
#include "str.h"
rx_t *rx_compile (const char *s, int flags) {
#include "str.h"
rx_t *rx_compile (const char *s, int flags) {
- rx_t *pp =
safe
_calloc (1, sizeof (rx_t));
+ rx_t *pp =
mem
_calloc (1, sizeof (rx_t));
pp->pattern = str_dup (s);
pp->pattern = str_dup (s);
- pp->rx =
safe
_calloc (1, sizeof (regex_t));
+ pp->rx =
mem
_calloc (1, sizeof (regex_t));
if (REGCOMP(pp->rx, NONULL (s), flags) != 0)
rx_free (&pp);
if (REGCOMP(pp->rx, NONULL (s), flags) != 0)
rx_free (&pp);
@@
-25,10
+25,10
@@
rx_t *rx_compile (const char *s, int flags) {
}
void rx_free (rx_t** p) {
}
void rx_free (rx_t** p) {
-
FREE
(&(*p)->pattern);
+
mem_free
(&(*p)->pattern);
regfree ((*p)->rx);
regfree ((*p)->rx);
-
FREE
(&(*p)->rx);
-
FREE
(p);
+
mem_free
(&(*p)->rx);
+
mem_free
(p);
}
int rx_compare (const rx_t* r1, const rx_t* r2) {
}
int rx_compare (const rx_t* r1, const rx_t* r2) {