aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authormarkster <markster@f38db490-d61c-443f-a65b-d21fe96a405b>2004-12-19 20:50:55 +0000
committermarkster <markster@f38db490-d61c-443f-a65b-d21fe96a405b>2004-12-19 20:50:55 +0000
commite5d58524be40d77f9d4717c40afff6b5c31fb1c3 (patch)
treebd5360dc721d464d22105d742311582153aeef35 /include
parent65750c5590f9f7dbdeec2717ce2320fc0893540d (diff)
Merge drumkilla's bitfield patch for SIP (bug #3083)
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@4487 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'include')
-rwxr-xr-xinclude/asterisk/utils.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/include/asterisk/utils.h b/include/asterisk/utils.h
index b70a1ffca..c1ed65504 100755
--- a/include/asterisk/utils.h
+++ b/include/asterisk/utils.h
@@ -23,8 +23,8 @@
#define ast_clear_flag(p,flag) ((p)->flags &= ~(flag))
-#define ast_copy_flags(dest,src,flagz) do { dest->flags &= ~(flagz); \
- dest->flags |= (src->flags & flagz); } while(0)
+#define ast_copy_flags(dest,src,flagz) do { (dest)->flags &= ~(flagz); \
+ (dest)->flags |= ((src)->flags & (flagz)); } while(0)
#define ast_set2_flag(p,value,flag) ((value) ? ast_set_flag(p,flag) : ast_clear_flag(p,flag))
@@ -38,6 +38,9 @@ struct ast_hostent {
char buf[1024];
};
+struct ast_flags {
+ int flags;
+};
extern char *ast_strip(char *buf);
extern struct hostent *ast_gethostbyname(const char *host, struct ast_hostent *hp);