You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by "Jay Freeman (saurik)" <sa...@saurik.com> on 2002/01/08 20:36:18 UTC
r761: Could not read status line: connection was closed by server.
OK, I am creating my repository, and then attempting to do a checkout
with r761. I have Apache's HEAD from last night, as well as APR's. I
worked out all of the Berkeley / apr-util mismatches, and now I'm
getting a funny error from svn :).
apr_error: #20014, src_err 0 : <Error string not specified yet>
Could not read status line: connection was closed by server.
Default Apache 2.0 configuration with changes to User/Group, Listen,
ServerName, and added Location entries for Subversion.
I'm getting to my error log:
[Tue Jan 08 14:18:48 2002] [notice] child pid 17616 exit signal
Segmentation fault (11)
[Tue Jan 08 14:18:48 2002] [notice] child pid 17595 exit signal
Segmentation fault (11)
I'm also getting what looks like some crazy memory corruption to other
log entries, so there is also the possibility this is an Apache problem.
Specifically, IP addresses get screwed up:
*whatever* ... [client 2O.2O.1Mq.2N8] . *other stuff*
Anyone else getting this? The only other mention I could find were
quite old versions which were running into similar problems, but that
seemed to be due to Apache dropping persistent connections (which was
then deactivated temporarily, and didn't seem to involve anything
_crashing_). OK, just verified that it still happens with the latest
Apache and the latest Subversion (had it compiling in the background
while typing this e-mail).
I need to get to my day's classes now, but when I get back I'll work on
debugging Apache to figure out where it is crashing.
Sincerely,
Jay Freeman (saurik)
saurik@saurik.com
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: r761: Could not read status line (New Info)
Posted by Greg Stein <gs...@lyra.org>.
As Jay found, you cannot simply set the value to NULL :-)
If the FS doesn't return the property, then that means it isn't defined.
Therefore, the function should just bail and return DAV_PROP_INSERT_NOTDEF.
mod_dav will Do The Right Thing from there:
* if a client specifically asks for it, they get a 404 for that prop
* if the clients asks for "all [available] props", then it simply won't be
present in the result
Cheers,
-g
p.s. and hoo boy, I gotta change that function to allow an error return...
On Wed, Jan 09, 2002 at 11:49:41PM -0600, Jay Freeman (saurik) wrote:
> Ben:
>
> OK, I did an update just now, and noticed that someone added the code to
> set value to NULL. Unfortunately, later code doesn't want to jive.
> First, there's that "assert: value != NULL" comment that should worry
> SOMEONE :).
>
> The later code is doing checks based on *value == '\0', and is using
> sprintf() on the result even if there isn't one (which would generate a
> nasty "(null)" in the output)... this code seems like it would be
> happier if value were set to "" rather than NULL. To point out, I tried
> changing the current code from value = NULL to value = "" and it
> at least _seems_ to work now.
>
> [root(4)@dreadnought bin]# gdb httpd
> GNU gdb Red Hat Linux (5.1-2)
> Copyright 2001 Free Software Foundation, Inc.
> GDB is free software, covered by the GNU General Public License, and you
> are
> welcome to change it and/or distribute copies of it under certain
> conditions.
> Type "show copying" to see the conditions.
> There is absolutely no warranty for GDB. Type "show warranty" for
> details.
> This GDB was configured as "i386-redhat-linux"...
> (gdb) run -X
> Starting program: /usr/local/apache2/bin/httpd -X
> [New Thread 1024 (LWP 30061)]
>
> Program received signal SIGSEGV, Segmentation fault.
> [Switching to Thread 1024 (LWP 30061)]
> 0x40048109 in dav_svn_insert_prop (resource=0xbfffeb74, propid=20026,
> what=DAV_PROP_INSERT_VALUE, phdr=0xbfffea70)
> at subversion/mod_dav_svn/liveprops.c:360
> 360 if (what == DAV_PROP_INSERT_NAME
> (gdb) list
> 355 /* get the information and global NS index for the property */
> 356 global_ns = dav_get_liveprop_info(propid,
> &dav_svn_liveprop_group, &info);
> 357
> 358 /* assert: info != NULL && info->name != NULL */
> 359
> 360 if (what == DAV_PROP_INSERT_NAME
> 361 || (what == DAV_PROP_INSERT_VALUE && *value == '\0')) {
> 362 s = apr_psprintf(p, "<lp%d:%s/>" DEBUG_CR, global_ns,
> info->name);
> 363 }
> 364 else if (what == DAV_PROP_INSERT_VALUE) {
> (gdb) print value
> $1 = 0x0
> (gdb)
>
> Sincerely,
> Jay Freeman (saurik)
> saurik@saurik.com
>
> -----Original Message-----
> From: sussman@collab.net [mailto:sussman@collab.net]
> Sent: Wednesday, January 09, 2002 10:40 AM
> To: Jay Freeman (saurik)
> Cc: svn-dev
> Subject: Re: r761: Could not read status line (New Info)
>
> "Jay Freeman \(saurik\)" <sa...@saurik.com> writes:
>
> > 189 value = apr_xml_quote_string(p, last_author->data, 1);
> > (gdb) print last_author
> > $1 = (struct {...} *) 0x0
> > (gdb) list
> > 184 /* ### what to do? */
> > 185 value = "###error###";
> > 186 break;
> > 187 }
> > 188
> > 189 value = apr_xml_quote_string(p, last_author->data, 1);
> > 190 break;
>
> Thanks, Jay. I see the problem.
>
> Greg, if the client explicitly requests a creator-displayname
> property, and the fs returns a NULL value, what should
> dav_svn_insert_prop do? Just set 'value' to NULL as well?
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
> For additional commands, e-mail: dev-help@subversion.tigris.org
--
Greg Stein, http://www.lyra.org/
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
RE: r761: Could not read status line (New Info)
Posted by "Jay Freeman (saurik)" <sa...@saurik.com>.
Ben:
OK, I did an update just now, and noticed that someone added the code to
set value to NULL. Unfortunately, later code doesn't want to jive.
First, there's that "assert: value != NULL" comment that should worry
SOMEONE :).
The later code is doing checks based on *value == '\0', and is using
sprintf() on the result even if there isn't one (which would generate a
nasty "(null)" in the output)... this code seems like it would be
happier if value were set to "" rather than NULL. To point out, I tried
changing the current code from value = NULL to value = "" and it
at least _seems_ to work now.
[root(4)@dreadnought bin]# gdb httpd
GNU gdb Red Hat Linux (5.1-2)
Copyright 2001 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you
are
welcome to change it and/or distribute copies of it under certain
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for
details.
This GDB was configured as "i386-redhat-linux"...
(gdb) run -X
Starting program: /usr/local/apache2/bin/httpd -X
[New Thread 1024 (LWP 30061)]
Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 1024 (LWP 30061)]
0x40048109 in dav_svn_insert_prop (resource=0xbfffeb74, propid=20026,
what=DAV_PROP_INSERT_VALUE, phdr=0xbfffea70)
at subversion/mod_dav_svn/liveprops.c:360
360 if (what == DAV_PROP_INSERT_NAME
(gdb) list
355 /* get the information and global NS index for the property */
356 global_ns = dav_get_liveprop_info(propid,
&dav_svn_liveprop_group, &info);
357
358 /* assert: info != NULL && info->name != NULL */
359
360 if (what == DAV_PROP_INSERT_NAME
361 || (what == DAV_PROP_INSERT_VALUE && *value == '\0')) {
362 s = apr_psprintf(p, "<lp%d:%s/>" DEBUG_CR, global_ns,
info->name);
363 }
364 else if (what == DAV_PROP_INSERT_VALUE) {
(gdb) print value
$1 = 0x0
(gdb)
Sincerely,
Jay Freeman (saurik)
saurik@saurik.com
-----Original Message-----
From: sussman@collab.net [mailto:sussman@collab.net]
Sent: Wednesday, January 09, 2002 10:40 AM
To: Jay Freeman (saurik)
Cc: svn-dev
Subject: Re: r761: Could not read status line (New Info)
"Jay Freeman \(saurik\)" <sa...@saurik.com> writes:
> 189 value = apr_xml_quote_string(p, last_author->data, 1);
> (gdb) print last_author
> $1 = (struct {...} *) 0x0
> (gdb) list
> 184 /* ### what to do? */
> 185 value = "###error###";
> 186 break;
> 187 }
> 188
> 189 value = apr_xml_quote_string(p, last_author->data, 1);
> 190 break;
Thanks, Jay. I see the problem.
Greg, if the client explicitly requests a creator-displayname
property, and the fs returns a NULL value, what should
dav_svn_insert_prop do? Just set 'value' to NULL as well?
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: r761: Could not read status line (New Info)
Posted by Ben Collins-Sussman <su...@collab.net>.
"Jay Freeman \(saurik\)" <sa...@saurik.com> writes:
> 189 value = apr_xml_quote_string(p, last_author->data, 1);
> (gdb) print last_author
> $1 = (struct {...} *) 0x0
> (gdb) list
> 184 /* ### what to do? */
> 185 value = "###error###";
> 186 break;
> 187 }
> 188
> 189 value = apr_xml_quote_string(p, last_author->data, 1);
> 190 break;
Thanks, Jay. I see the problem.
Greg, if the client explicitly requests a creator-displayname
property, and the fs returns a NULL value, what should
dav_svn_insert_prop do? Just set 'value' to NULL as well?
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
RE: r761: Could not read status line (New Info)
Posted by "Jay Freeman (saurik)" <sa...@saurik.com>.
OK, I found where the error is occurring, but I'm still not sure why...
:-P
Here is my thought: the new CR code is trying to read the property for
whether or not translation is requested (I don't know exactly how this
works as I finally decided to opt out of that thread when it started
looking titanic and I went on vacation, hehe).
Unfortunately, I don't have a revision yet, so all the data that comes
back for that property is NULL'd out, but there isn't a check for it.
It likely requires a small if (last_author == NULL) check, but I
don't know what would go into it... (maybe set value to an empty
string?).
Here is what I got out of gdb:
[root(3)@dreadnought bin]# gdb httpd
GNU gdb Red Hat Linux (5.1-2)
Copyright 2001 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you
are
welcome to change it and/or distribute copies of it under certain
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for
details.
This GDB was configured as "i386-redhat-linux"...r
(gdb) run -X
Starting program: /usr/local/apache2/bin/httpd -X
[New Thread 1024 (LWP 32544)]
Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 1024 (LWP 32544)]
0x40047d38 in dav_svn_insert_prop (resource=0xbffff534, propid=20026,
what=DAV_PROP_INSERT_VALUE, phdr=0xbffff430)
at subversion/mod_dav_svn/liveprops.c:189
189 value = apr_xml_quote_string(p, last_author->data, 1);
(gdb) print last_author
$1 = (struct {...} *) 0x0
(gdb) list
184 /* ### what to do? */
185 value = "###error###";
186 break;
187 }
188
189 value = apr_xml_quote_string(p, last_author->data, 1);
190 break;
191 }
192
193 case DAV_PROPID_getcontentlanguage:
(gdb)
Sincerely,
Jay Freeman (saurik)
saurik@saurik.com
-----Original Message-----
From: Karl Fogel [mailto:kfogel@newton.ch.collab.net]
Sent: Tuesday, January 08, 2002 3:22 PM
To: Jay Freeman (saurik)
Cc: svn-dev
Subject: Re: r761: Could not read status line: connection was closed by
server.
Thanks, Jay; when you're debugging, update to the very latest, as some
changes have been made in mod_dav_svn since rev 761. I don't know if
they would be relevant to a memory leak, but it can't hurt to see.
-Karl
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: r761: Could not read status line: connection was closed by server.
Posted by Karl Fogel <kf...@newton.ch.collab.net>.
Thanks, Jay; when you're debugging, update to the very latest, as some
changes have been made in mod_dav_svn since rev 761. I don't know if
they would be relevant to a memory leak, but it can't hurt to see.
-Karl
"Jay Freeman \(saurik\)" <sa...@saurik.com> writes:
> OK, I am creating my repository, and then attempting to do a checkout
> with r761. I have Apache's HEAD from last night, as well as APR's. I
> worked out all of the Berkeley / apr-util mismatches, and now I'm
> getting a funny error from svn :).
>
> apr_error: #20014, src_err 0 : <Error string not specified yet>
> Could not read status line: connection was closed by server.
>
> Default Apache 2.0 configuration with changes to User/Group, Listen,
> ServerName, and added Location entries for Subversion.
>
> I'm getting to my error log:
>
> [Tue Jan 08 14:18:48 2002] [notice] child pid 17616 exit signal
> Segmentation fault (11)
> [Tue Jan 08 14:18:48 2002] [notice] child pid 17595 exit signal
> Segmentation fault (11)
>
> I'm also getting what looks like some crazy memory corruption to other
> log entries, so there is also the possibility this is an Apache problem.
> Specifically, IP addresses get screwed up:
>
> *whatever* ... [client 2O.2O.1Mq.2N8] . *other stuff*
>
> Anyone else getting this? The only other mention I could find were
> quite old versions which were running into similar problems, but that
> seemed to be due to Apache dropping persistent connections (which was
> then deactivated temporarily, and didn't seem to involve anything
> _crashing_). OK, just verified that it still happens with the latest
> Apache and the latest Subversion (had it compiling in the background
> while typing this e-mail).
>
> I need to get to my day's classes now, but when I get back I'll work on
> debugging Apache to figure out where it is crashing.
>
> Sincerely,
> Jay Freeman (saurik)
> saurik@saurik.com
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
> For additional commands, e-mail: dev-help@subversion.tigris.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org