Merge drumkilla's bitfield patch for SIP (bug #3083)

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@4487 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Mark Spencer
2004-12-19 20:50:55 +00:00
parent bfaa2734a6
commit d6a415c262
2 changed files with 188 additions and 197 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -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);