Re: Basic, but what the hell am I doing wrong here?

2004-06-10 Thread Brent Miller
Stephen Touset wrote: >I'm working on a fairly large program for a class, and now every time I >run it, it segfaults. > >I've secluded the part that seems to cause the problems, and wrote a >small file called test.cc, which contains a minimal implementation fo >the code that brings up the segfault

Re: Basic, but what the hell am I doing wrong here?

2004-06-10 Thread Simon Kitching
On Fri, 2004-06-11 at 14:49, Kevin Mark wrote: > On Thu, Jun 10, 2004 at 09:36:04PM -0400, Stephen Touset wrote: > > I've opened and read files hundreds of times in my life. What gives now? > > > > -- > > Stephen Touset <[EMAIL PROTECTED]> > > > #include > > > > using namespace std; > > > > i

Re: Basic, but what the hell am I doing wrong here?

2004-06-10 Thread Kevin Mark
On Thu, Jun 10, 2004 at 09:36:04PM -0400, Stephen Touset wrote: > I've opened and read files hundreds of times in my life. What gives now? > > -- > Stephen Touset <[EMAIL PROTECTED]> > #include > > using namespace std; > > int main(void) > { > > ifstream fin("test.cc"); > char* s

Re: Basic, but what the hell am I doing wrong here?

2004-06-10 Thread Stephen Touset
On Thu, 2004-06-10 at 21:42, William Ballard wrote: > On Thu, Jun 10, 2004 at 09:36:04PM -0400, Stephen Touset wrote: > > read(3, "#include \n\nusing namesp"..., 8192) = 218 > > read(3, "", 4096) = 0 > > --- SIGSEGV (Segmentation fault) @ 0 (0) --- > > +++ killed by SIGSEGV ++

Re: Basic, but what the hell am I doing wrong here?

2004-06-10 Thread William Ballard
On Thu, Jun 10, 2004 at 09:36:04PM -0400, Stephen Touset wrote: > read(3, "#include \n\nusing namesp"..., 8192) = 218 > read(3, "", 4096) = 0 > --- SIGSEGV (Segmentation fault) @ 0 (0) --- > +++ killed by SIGSEGV +++ Shouldn't you get symbols for read() and step into that? An

Basic, but what the hell am I doing wrong here?

2004-06-10 Thread Stephen Touset
I'm working on a fairly large program for a class, and now every time I run it, it segfaults. I've secluded the part that seems to cause the problems, and wrote a small file called test.cc, which contains a minimal implementation fo the code that brings up the segfault. It's attached. The code sim