Hi Ambrus, Yes, the source code is from a example of SYNOPSIS, and I removed the comments.
Hi Marc, Sorry for misformatted source code, my compilation steps for libev-4.11 under minGW32(Windows 7 x64) are below: 1. ./configure 2. make 3. make install and I compile my program like this, gcc -o svr test_svr.c -I libev-4.11 -L /usr/local/lib -lev -lws2_32 all things are OK, but run the app, will crash. 2012/12/6 <libev-requ...@lists.schmorp.de> > Send libev mailing list submissions to > libev@lists.schmorp.de > > To subscribe or unsubscribe via the World Wide Web, visit > http://lists.schmorp.de/cgi-bin/mailman/listinfo/libev > or, via email, send a message with subject or body 'help' to > libev-requ...@lists.schmorp.de > > You can reach the person managing the list at > libev-ow...@lists.schmorp.de > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of libev digest..." > > > Today's Topics: > > 1. Re: a segmentation fault on minGW (Marc Lehmann) > 2. Re: a segmentation fault on minGW (Zsb?n Ambrus) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Wed, 5 Dec 2012 13:21:12 +0100 > From: Marc Lehmann <schm...@schmorp.de> > To: ntishuishengliao <ntishuishengl...@ntius.com> > Cc: libev <libev@lists.schmorp.de> > Subject: Re: a segmentation fault on minGW > Message-ID: <20121205122111.gb9...@schmorp.de> > Content-Type: text/plain; charset=us-ascii > > On Sat, Dec 01, 2012 at 11:57:30PM +0800, ss_liao <ss_l...@163.com> wrote: > > I'm beginner on libev, I can compile libev-4.11 in minGW, and I write > some code like this: > > Your code is badly misformatted, so I mightoverlook some detail, but it > looks > ok. > > > ev_io_start (loop, &stdin_watcher); > > ev_timer_start (loop, &timeout_watcher); > > it probably crashes on either of these lines, and if yourdebugging output > is > correct (it might not be) then it's because loop is 0. > > I am afraid you have to debug this yourself - however, did you compile > libev using the same compiler and flags as your program, and are you sure > you > are linking to the right libev? > > -- > The choice of a Deliantra, the free code+content > MORPG > -----==- _GNU_ http://www.deliantra.net > ----==-- _ generation > ---==---(_)__ __ ____ __ Marc Lehmann > --==---/ / _ \/ // /\ \/ / schm...@schmorp.de > -=====/_/_//_/\_,_/ /_/\_\ > > > > ------------------------------ > > Message: 2 > Date: Wed, 5 Dec 2012 17:28:19 +0100 > From: Zsb?n Ambrus <amb...@math.bme.hu> > To: libev <libev@lists.schmorp.de> > Subject: Re: a segmentation fault on minGW > Message-ID: > < > cahku1chxceajnjnng+nnyfg+gasxuqe+7yredabiq6oqdut...@mail.gmail.com> > Content-Type: text/plain; charset=ISO-8859-1 > > On 12/5/12, Marc Lehmann <schm...@schmorp.de> wrote: > > Your code is badly misformatted, so I mightoverlook some detail, but it > > looks ok. > > It's supposed to look ok, because it's the example program from the > SYNOPSIS section of the libev manual, only it's reformatted and most > comments are removed. > > Ambrus > > > > ------------------------------ > > _______________________________________________ > libev mailing list > libev@lists.schmorp.de > http://lists.schmorp.de/cgi-bin/mailman/listinfo/libev > > End of libev Digest, Vol 62, Issue 3 > ************************************ >
_______________________________________________ libev mailing list libev@lists.schmorp.de http://lists.schmorp.de/cgi-bin/mailman/listinfo/libev