[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: r727 doesn't build w/ --disable-shared

From: Colin Putney <cputney_at_whistler.net>
Date: 2002-01-08 10:11:38 CET

On Monday, January 7, 2002, at 07:44 AM, Garrett Rooney wrote:

> yeah, i imagine there's something wrong with the way we're building
> berkeley db in the tree. now that you mention it, i think i saw this
> problem this weekend when i was trying to build svn on my ibook under
> osx. i just assumed it was something weird on osx, but i guess it's
> more widespread.

Yeah, I wasn't able to build bdb-4.0.14 in-tree on OS X either. It works
fine configured as --with-berkeley-db=/usr/local/BerkeleyDB.4.0 though.

> (of course more troubling are the Bus Errors i get inside of apr on os
> x, but more on that when i have time to get back to it...)

I can add a few more data points to this one.

The Bus Error is caused when apr attempts to call a null function
pointer. Specifically, apr_pvsprintf() calls apr_vformatter(), passing
it a pointer to psprintf_flush(), which gets called to add bits of
formatted string to the string buffer. Somehow apr_pvsprintf() passes a
null pointer, which causes the crash.

Two things I've managed to determine:

1) This doesn't seem to be related to the fact that psprintf_flush() is
declared as a static function

2) configuring for shared libraries (ie, no --disable-shared) doesn't
fix the problem, but it might affect where the crash occurs.

I'm going to play around with it some more tomorrow, but in the
meantime, here's a gdb backtrace taken from a statically linked svn
(note the first parameter to apr_vformatter() in frame #1) :

Program received signal EXC_BAD_ACCESS, Could not access memory.
0x00000000 in ?? ()
(gdb) bt
#0 0x00000000 in ?? ()
Cannot access memory at address 0x0
#1 0x00065b3c in apr_vformatter (flush_func=0, vbuff=0xbfffec68,
fmt=0xc054a " gmt_off %06d)", ap=0xbfffed18 "?\200") at
apr_snprintf.c:724
#2 0x0004d40c in apr_psprintf (p=0xbfffec68, fmt=0xc0518 "%s %d %s %d
%02d:%02d:%02d.%06d (day %03d, dst %d, gmt_off %06d)") at
apr_pools.c:1213
#3 0x000622e0 in svn_time_to_nts (t=18437366891860040, pool=0x306d98)
at subversion/libsvn_subr/time.c:67
#4 0x00014350 in normalize_entry (entry=0x2eb360, pool=0x4180b0) at
subversion/libsvn_wc/entries.c:558
#5 0x00014cf0 in svn_wc__entries_write (entries=0x306d98,
path=0x2e1460, pool=0x4180b0) at subversion/libsvn_wc/entries.c:980
#6 0x0001580c in svn_wc__entry_modify (path=0x2e1460, name=0x306cb8,
modify_flags=64, revision=-1, kind=svn_node_none,
schedule=svn_wc_schedule_normal, conflicted=0, copied=0,
text_time=1010464848000000, prop_time=0, url=0x0, attributes=0x306bc8,
pool=0x4180b0) at subversion/libsvn_wc/entries.c:1402
#7 0x00024d94 in log_do_modify_entry (loggy=0x418aa8, name=0x2e0185
"configure.in", atts=0x2df590) at subversion/libsvn_wc/log.c:424
#8 0x00025c54 in start_handler (userData=0x418aa8, eltname=0x2e0178
"modify-entry", atts=0x2df590) at subversion/libsvn_wc/log.c:861
#9 0x0006b2dc in doContent (parser=0x2df3b0, startTagLevel=0,
enc=0xc9060, s=0xbffff2a4 "<modify-entry\n name=\"configure.in\"\n
text-time=\"working\"/>\n?? end=0xbffff2e2 "?? nextPtr=0xbffff0f8) at
expat-lite/xmlparse.c:1299
#10 0x0006a25c in contentProcessor (parser=0x2df3b0, start=0xbffff1a8
"<mv\n dest=\".svn/text-base/configure.in.svn-base\"\n
name=\".svn/tmp/text-base/configure.in.svn-base\"/>\n<cp\n
dest=\"configure.in\"\n name=\".svn/text-base/configure.in.svn-
base\"/>\n<modify-entry\n nam"..., end=0xbffff2e2 "??
endPtr=0xbffff0f8) at expat-lite/xmlparse.c:955
#11 0x00069954 in XML_Parse (parser=0x2df3b0, s=0xbffff1a8 "<mv\n
dest=\".svn/text-base/configure.in.svn-base\"\n
name=\".svn/tmp/text-base/configure.in.svn-base\"/>\n<cp\n
dest=\"configure.in\"\n name=\".svn/text-base/configure.in.svn-
base\"/>\n<modify-entry\n nam"..., len=314, isFinal=0) at expat-
lite/xmlparse.c:783
#12 0x00061984 in svn_xml_parse (svn_parser=0x4141a8, buf=0xbffff1a8
"<mv\n dest=\".svn/text-base/configure.in.svn-base\"\n
name=\".svn/tmp/text-base/configure.in.svn-base\"/>\n<cp\n
dest=\"configure.in\"\n name=\".svn/text-base/configure.in.svn-
base\"/>\n<modify-entry\n nam"..., len=314, is_final=0) at
subversion/libsvn_subr/xml.c:273
#13 0x00026058 in svn_wc__run_log (path=0x2e1460, pool=0x4180b0) at
subversion/libsvn_wc/log.c:953
#14 0x00012a70 in close_file (file_baton=0x4181c8) at
subversion/libsvn_wc/get_editor.c:1595
#15 0x0005995c in close_file (file_baton=0x303a60) at
subversion/libsvn_delta/compose_editors.c:206
#16 0x0002be18 in fetch_file (sess=0x2de360, rsrc=0x2e4ad8,
dir_baton=0x2d6d58, vuh=0xbffff7c8, editor=0x2d65d8, pool=0x2d62e0) at
subversion/libsvn_ra_dav/fetch.c:465
#17 0x0002c760 in svn_ra_dav__do_checkout (session_baton=0x2d66d8,
revision=-1, recurse=1, editor=0x2d65d8, edit_baton=0x2d65c0) at
subversion/libsvn_ra_dav/fetch.c:751
#18 0x0000d6a0 in svn_client_checkout (before_editor=0x0,
before_edit_baton=0x0, after_editor=0x2d6550, after_edit_baton=0x2d6548,
auth_baton=0x2d6528, URL=0x2d6518, path=0x2d64b0, revision=-1,
recurse=1, tm=0, xml_src=0x0, pool=0x2d62e0) at
subversion/libsvn_client/checkout.c:115
#19 0x00004e44 in svn_cl__checkout (os=0x2d6460, opt_state=0xbffff974,
pool=0x2d62e0) at subversion/clients/cmdline/checkout-cmd.c:119
#20 0x00006170 in main (argc=5, argv=0xbffffa9c) at
subversion/clients/cmdline/main.c:610
#21 0x00002664 in _start ()
#22 0x00002494 in start ()

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sat Oct 21 14:36:55 2006

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.