When attempting to run fossil add . or fossil add somedirectory name fossil core dumps with the following error:

fossil in free(): error: chunk is already free 0x203aca520
Abort trap (core dumped)

This is on OpenBSD amd64 with the latest from trunk.

Doing something like fossil add somedirectory/* works.

I confirm, I get same problem on OpenBSD 4.7 (i386).. I don't have this problem on MacOS X 10.6.7.
Here the output of a backtrace on gdb when adding a directory under OpenBSD:

<verbatim>
$ gdb
GNU gdb 6.3
Copyright 2004 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-unknown-openbsd4.7"...
(gdb) r add usr
Starting program: add usr
fossil in free(): error: chunk is already free

Program received signal SIGABRT, Aborted.
0x02003a71 in kill () from
(gdb) bt
#0  0x02003a71 in kill () from
#1  0x0204f313 in abort () at
#2  0x02024c99 in wrterror (p=0x21fce6f5 "chunk is already free")
    at
#3  0x02026688 in ofree (p=0x84d271c0) at
#4  0x02026781 in free (ptr=0x7fb31800) at
#5  0x1c04d79a in sqlite3_free (p=0x7fb31808) at src/sqlite3.c:18157
#6  0x1c068571 in sqlite3VdbeDeleteObject (db=0x7c9f5c08, p=0x7c48e608) at src/sqlite3.c:59390
#7  0x1c068607 in sqlite3VdbeDelete (p=0x52f5) at src/sqlite3.c:59417
#8  0x1c068480 in sqlite3VdbeFinalize (p=0x7c48e608) at src/sqlite3.c:59351
#9  0x1c08559b in sqlite3_exec (db=0x7c9f5c08,
    zSql=0x87960700 "INSERT INTO xCallback=0, pArg=0x0, pzErrMsg=0xcfbdbbec) at src/sqlite3.c:86283
#10 0x1c00ec08 in db_multi_exec (
    zSql=0x3c0001e0 "INSERT INTO vfile(vid,deleted,rid,mrid,pathname,isexe)VALUES(%d,0,0,0,%Q,%d)")
    at bld/db_.c:446
#11 0x1c00285b in add_one_file (zPath=0x88febbc8 vid=1)
    at bld/add_.c:115
#12 0x1c002942 in add_files_in_sfile (vid=1) at bld/add_.c:152
#13 0x1c002a95 in add_cmd () at bld/add_.c:234
#14 0x1c022628 in main (argc=2, argv=0xcfbdbe18) at bld/main_.c:289

</verbatim>

Hope this can help

I've notice that latest release (OpenBSD 4.7 binary from Download page), with the same test is ok.

Sorry, I gave Wrong info before.. it's the same problem on OSX.. When I first tried, I've build the latest version from trunk, but I forget to put the executable on the PATH.