Assertion failure in today's SVN 20080407

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello list,

when using a 'config_site.h' with:

  #define PJ_CONFIG_MINIMAL_SIZE
  #include <pj/config_site_sample.h>

...the file pj/config_site_sample.h defines:

  #define PJ_IOQUEUE_MAX_HANDLES 16

This seems to be too low, because later on in line 45 of
pjlib/src/pj/sock_select.c:

  pj_assert(sizeof(pj_fd_set_t)-sizeof(pj_sock_t) >= sizeof(fd_set));

The size of 'fd_set' is 128 at least on the Debian Linux on ARM
platform I'm using (Maemo SDK with scratchbox GCC compiler). I'll
leave it up to you to do the math, but the assertion will fail.

Because pj_fd_set_t is an opaque buffer for fd_set, it seems
reasonable to increase the value of PJ_IOQUEUE_MAX_HANDLES to
28 or even 32 should rounding off be desirable:

Index: pjlib/include/pj/config_site_sample.h
--- pjlib/include/pj/config_site_sample.h.orig  2008-04-07
11:19:39.000000000 +0200
+++ pjlib/include/pj/config_site_sample.h       2008-04-07
11:14:13.000000000 +0200
@@ -112,7 +112,7 @@
 #   define PJ_ENABLE_EXTRA_CHECK       0
 #   define PJ_HAS_ERROR_STRING         0
 #   undef PJ_IOQUEUE_MAX_HANDLES
-#   define PJ_IOQUEUE_MAX_HANDLES      16
+#   define PJ_IOQUEUE_MAX_HANDLES      32
 #   define PJ_IOQUEUE_HAS_SAFE_UNREG   0
 #   define PJSIP_MAX_TSX_COUNT         15
 #   define PJSIP_MAX_DIALOG_COUNT      15

Is there a better way to report bugs than sending messages to
this general purpose mailing list?

Regards,
Michael



[Index of Archives]     [Asterisk Users]     [Asterisk App Development]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [Linux API]
  Powered by Linux