talons

Fork of Claws Mail https://www.claws-mail
Log | Files | Refs | README | LICENSE

commit 7f27738df23b2098214d956e6b41149c1a158404
parent d10b5af20399f8711a8f5ce0172cb33b68c97977
Author: Colin Leroy <colin@colino.net>
Date:   Fri, 14 Jun 2013 10:34:17 +0200

More win32 fixes

Diffstat:
Msrc/matcher.c | 6++++++
Msrc/matcher.h | 2++
2 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/src/matcher.c b/src/matcher.c @@ -313,7 +313,9 @@ MatcherProp *matcherprop_new(gint criteria, const gchar *header, prop->expr = expr != NULL ? g_strdup(expr) : NULL; prop->matchtype = matchtype; +#ifndef G_OS_WIN32 prop->preg = NULL; +#endif prop->value = value; prop->error = 0; @@ -330,10 +332,12 @@ void matcherprop_free(MatcherProp *prop) { g_free(prop->expr); g_free(prop->header); +#ifndef G_OS_WIN32 if (prop->preg != NULL) { regfree(prop->preg); g_free(prop->preg); } +#endif g_free(prop); } @@ -353,7 +357,9 @@ MatcherProp *matcherprop_copy(const MatcherProp *src) prop->expr = src->expr ? g_strdup(src->expr) : NULL; prop->matchtype = src->matchtype; +#ifndef G_OS_WIN32 prop->preg = NULL; /* will be re-evaluated */ +#endif prop->value = src->value; prop->error = src->error; return prop; diff --git a/src/matcher.h b/src/matcher.h @@ -36,7 +36,9 @@ struct _MatcherProp { gchar *header; gchar *expr; int value; +#ifndef G_OS_WIN32 regex_t *preg; +#endif int error; gboolean result; gboolean done;