Re: rtems libbsd gethostbyname did not work

yao0718 29171383 at qq.com
Mon Jul 4 16:12:51 UTC 2016


sure, I configure the CONFIGURE_MAXIMUM_POSIX_RWLOCKS and now it's work fine, thanks for your help 


------------------ 原始邮件 ------------------
发件人: "Sebastian Huber";<sebastian.huber at embedded-brains.de>;
发送时间: 2016年7月4日(星期一) 中午1:56
收件人: "yao0718"<29171383 at qq.com>; "users"<users at rtems.org>; 

主题: Re: rtems libbsd gethostbyname did not work





On 30/06/16 15:42, 葡萄 wrote:
> hi,I port a usb driver form freebsd for 4G dongle, it work ,but I 
> cannot use gethostbyname ,I add some code for debug,find in 
> freebsd/lib/libc/net/gethostnamadr.c line 581  _nsdispatch  return 
> failure, in function _nsdispatch ,
>
> if (isthreaded) {
> result = _pthread_rwlock_rdlock(&nss_lock);
> if (result != 0) {
> printf("nsdispatch pthread rd lock failure %d!\n",result);
> result = NS_UNAVAIL;
> goto fin;
> }
> }
> _pthread_rwlock_rdlock  return invalid, can you give me some advise? 
> how can i let gethostbyname work?
> below is shell print for application information

Check your application configuration, you probably didn't build with 
POSIX enabled or didn't configure enough rwlocks. Use the 
"default-init.h" of the libbsd as an example.

-- 
Sebastian Huber, embedded brains GmbH

Address : Dornierstr. 4, D-82178 Puchheim, Germany
Phone   : +49 89 189 47 41-16
Fax     : +49 89 189 47 41-09
E-Mail  : sebastian.huber at embedded-brains.de
PGP     : Public key available on request.

Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/users/attachments/20160705/1b684750/attachment-0002.html>


More information about the users mailing list