]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
Wed May 13 13:18:14 CDT 2009 Pekka Pessi <first.last@nokia.com>
authorMichael Jerris <mike@jerris.com>
Fri, 15 May 2009 16:15:28 +0000 (16:15 +0000)
committerMichael Jerris <mike@jerris.com>
Fri, 15 May 2009 16:15:28 +0000 (16:15 +0000)
  * msg_mclass_insert_header(): not using uninit data
  Ignore-this: 40a6993391b5f2993af8ee01c407c0c7

  Coverity issue.

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@13349 d0543943-73ff-0310-b7d9-9358b9ac24b2

libs/sofia-sip/.update
libs/sofia-sip/libsofia-sip-ua/msg/msg_mclass.c

index cf76eebff7d7ff7d01354dc7558372adc02755b1..60551332285df274f4d6083ca634022cd2a9c66c 100644 (file)
@@ -1 +1 @@
-Fri May 15 11:14:26 CDT 2009
+Fri May 15 11:14:57 CDT 2009
index 58c859615b2174ca02d14a4b6d990faf3a52c395..320ecc21b5acad088a8b9147d1e3e767057d0027 100644 (file)
@@ -164,25 +164,7 @@ int msg_mclass_insert_header(msg_mclass_t *mc,
                             msg_hclass_t *hc,
                             unsigned short offset)
 {
-  msg_href_t hr[1];
-
-  if (mc == NULL || hc == NULL) {
-    errno = EINVAL;
-    return -1;
-  }
-
-  if (msg_hclass_offset(mc, NULL, hc))
-    return (void)(errno = EEXIST), -1;
-
-  if (offset == 0)
-    offset = mc->mc_msize, mc->mc_msize += sizeof(msg_header_t *);
-
-  assert(offset < mc->mc_msize);
-
-  hr->hr_class = hc;
-  hr->hr_offset = offset;
-
-  return msg_mclass_insert(mc, hr);
+  return msg_mclass_insert_with_mask(mc, hc, offset, 0);
 }
 
 /**Add a new header to the message class.