I'm afraid the build is still broken and it looks like addresses
calculates in wrong way. Here is some details of crash.

roman:firebird$ gdb --args
/home/roman/prj/firebird/gen/Debug/firebird/bin/isql -q -i
/home/roman/prj/firebird/src/dbs/metadata.sql
GNU gdb (GDB) 7.5.1
Copyright (C) 2012 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-unknown-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from
/home/roman/prj/firebird/gen/Debug/firebird/bin/isql...done.
(gdb) shell rm /home/roman/prj/firebird/metadata.fdb
(gdb) r
Starting program: /home/roman/prj/firebird/gen/Debug/firebird/bin/isql
-q -i /home/roman/prj/firebird/src/dbs/metadata.sql
warning: no loadable sections found in added symbol-file
system-supplied DSO at 0x7ffff7ffa000
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[New Thread 0x7ffff5251700 (LWP 18002)]
[New Thread 0x7ffff4a50700 (LWP 18003)]

Program received signal SIGSEGV, Segmentation fault.
0x00007ffff6a0b454 in memset () from /lib/x86_64-linux-gnu/libc.so.6
(gdb) bt
#0  0x00007ffff6a0b454 in memset () from /lib/x86_64-linux-gnu/libc.so.6
#1  0x00007ffff3918317 in Firebird::ZeroBuffer::ZeroBuffer
(this=0x7ffff7f8a7b8, p=..., size=262144)
    at 
/home/roman/prj/firebird/src/include/../jrd/../jrd/../common/classes/File.h:59
#2  0x00007ffff39184e2 in
Firebird::InitInstance<Firebird::ZeroBuffer>::operator()
(this=0x7ffff424cf80 <zeros>)
    at /home/roman/prj/firebird/src/include/../common/classes/init.h:218
#3  0x00007ffff3915e2f in PIO_init_data (dbb=0x7ffff7f5f040,
main_file=0x7ffff7f4f770, status_vector=0x7fffffff8670, startPage=3,
    initPages=1) at /home/roman/prj/firebird/src/jrd/os/posix/unix.cpp:587
#4  0x00007ffff38272c5 in PAG_allocate (tdbb=0x7fffffffa1b0,
window=0x7fffffff87b0) at /home/roman/prj/firebird/src/jrd/pag.cpp:566
#5  0x00007ffff38d1d01 in DPM_allocate (tdbb=0x7fffffffa1b0,
window=0x7fffffff87b0)
    at /home/roman/prj/firebird/temp/Debug/jrd/dpm.cpp:236
#6  0x00007ffff38d2de9 in DPM_create_relation_pages
(tdbb=0x7fffffffa1b0, relation=0x7ffff7f2fc58,
relPages=0x7ffff7f2fe48)
    at /home/roman/prj/firebird/temp/Debug/jrd/dpm.cpp:696
#7  0x00007ffff38d2cfa in DPM_create_relation (tdbb=0x7fffffffa1b0,
relation=0x7ffff7f2fc58)
    at /home/roman/prj/firebird/temp/Debug/jrd/dpm.cpp:678
#8  0x00007ffff38e6a09 in INI_format (owner=..., charset=...) at
/home/roman/prj/firebird/temp/Debug/jrd/ini.cpp:1468
#9  0x00007ffff37d2fc6 in Jrd::JProvider::createDatabase
(this=0x7ffff7f87190, user_status=0x7ffff7fe82c0,
    filename=0x7ffff7fa86e0 "/home/roman/prj/firebird/metadata.fdb",
dpb_length=51,
    dpb=0x7fffffffadb8 "\001\034\006sysdba\035\tmasterkeyM") at
/home/roman/prj/firebird/src/jrd/jrd.cpp:2654
#10 0x00007ffff7a29fe1 in Why::Dispatcher::attachOrCreateDatabase
(this=0x7ffff7fe8cf0, status=0x7ffff7fe82c0, createFlag=true,
    filename=0x7fffffffaf7c "metadata.fdb", dpbLength=16,
dpb=0x7fffffffaff8 "\001\066\001")
    at /home/roman/prj/firebird/src/yvalve/why.cpp:5610
#11 0x00007ffff7a29af2 in Why::Dispatcher::createDatabase
(this=0x7ffff7fe8cf0, status=0x7ffff7fe82c0,
    filename=0x7fffffffaf7c "metadata.fdb", dpbLength=16,
dpb=0x7fffffffaff8 "\001\066\001")
    at /home/roman/prj/firebird/src/yvalve/why.cpp:5532
#12 0x00007ffff7a0dd34 in PREPARSE_execute (status=0x7ffff7fe82c0,
ptrAtt=0x7fffffffb118, stmt_length=45, stmt=0x7ffff7fe8ca5 "",
    stmt_eaten=0x7fffffffb116, dialect=1) at
/home/roman/prj/firebird/src/yvalve/preparse.cpp:263
#13 0x00007ffff7a126ff in Why::UtlInterface::executeCreateDatabase
(this=0x7ffff7dd52c0 <Why::utlInterface>,
    status=0x7ffff7fe82c0, stmtLength=0,
creatDBstatement=0x7ffff7fe8c78 "CREATE DATABASE 'metadata.fdb'
PAGE_SIZE 1024",
    dialect=1, stmtIsCreateDb=0x0) at
/home/roman/prj/firebird/src/yvalve/utl.cpp:579
#14 0x000000000041d85d in create_db (statement=0x7ffff5252040 "CREATE
DATABASE 'metadata.fdb' PAGE_SIZE 1024",
    d_name=0x7ffff7fe8bb8 "'metadata.fdb'") at
/home/roman/prj/firebird/temp/Debug/isql/isql.cpp:5318
#15 0x000000000041fb62 in frontend (statement=0x7ffff5252040 "CREATE
DATABASE 'metadata.fdb' PAGE_SIZE 1024")
    at /home/roman/prj/firebird/temp/Debug/isql/isql.cpp:6242
#16 0x0000000000421b41 in get_statement (statement=0x7ffff5252040
"CREATE DATABASE 'metadata.fdb' PAGE_SIZE 1024",
    bufsize=10485760, statement_prompt=0x481ac9 "SQL> ") at
/home/roman/prj/firebird/temp/Debug/isql/isql.cpp:7109
#17 0x000000000041e0dc in do_isql () at
/home/roman/prj/firebird/temp/Debug/isql/isql.cpp:5574
#18 0x00000000004145b2 in ISQL_main (argc=4, argv=0x7fffffffde98) at
/home/roman/prj/firebird/temp/Debug/isql/isql.cpp:1646
#19 0x00000000004142b0 in main (argc=4, argv=0x7fffffffde98) at
/home/roman/prj/firebird/temp/Debug/isql/isql.cpp:1558
(gdb) up
#1  0x00007ffff3918317 in Firebird::ZeroBuffer::ZeroBuffer
(this=0x7ffff7f8a7b8, p=..., size=262144)
    at 
/home/roman/prj/firebird/src/include/../jrd/../jrd/../common/classes/File.h:59
59 memset(bufAligned, 0, size);
(gdb) print bufAligned
$1 = 0xf217e000 <Address 0xf217e000 out of bounds>
(gdb) up
#2  0x00007ffff39184e2 in
Firebird::InitInstance<Firebird::ZeroBuffer>::operator()
(this=0x7ffff424cf80 <zeros>)
    at /home/roman/prj/firebird/src/include/../common/classes/init.h:218
218 instance = FB_NEW(*getDefaultMemoryPool()) T(*getDefaultMemoryPool());
(gdb) quit
A debugging session is active.

Inferior 1 [process 17998] will be killed.

Quit anyway? (y or n) y
roman:firebird$ git svn info
Path: .
URL: svn+ssh://svn.code.sf.net/p/firebird/code/firebird/trunk
Repository Root: svn+ssh://svn.code.sf.net/p/firebird/code
Repository UUID: 65644016-39b1-43b1-bf79-96bc8fe82c15
Revision: 59891
Node Kind: directory
Schedule: normal
Last Changed Author: firebirds
Last Changed Rev: 59891
Last Changed Date: 2014-07-19 04:31:00 +0400 (Сб., 19 июля 2014)

2014-07-18 19:50 GMT+04:00 Nikolay Samofatov <nikolay.samofa...@red-soft.biz>:
> Philippe,
>
> Apparently that was me who broke the build for you.
>
> The code compiled for my Linux build configuration, but produced warnings.
>
> I noticed that, and committed fix a few hours later (
>
> Revision: 59884
>            http://sourceforge.net/p/firebird/code/59884
> Author:   skidder
> Date:     2014-07-17 21:17:15 +0000 (Thu, 17 Jul 2014)
> Log Message:
> -----------
> Fix GCC warnings
> )
>
> It apparently didn't get into SVN before you created the snapshot build.
>
> Code still produces warnings for older GCC versions (e.g. GCC 4.4.7), but 
> builds cleanly with newer
> ones (e.g. GCC 4.9.1).
>
> New code is perfectly valid C++11 (you can use "offsetof" macro for non-POD 
> "standard-layout"
> classes there). NULL pointer tricks that were used by Firebird before always 
> were "undefined behavior".
>
> Please report if next snapshot fails for you again.
>
> Thank you,
> Nikolay Samofatov
>
>
> ------------------------------------------------------------------------------
> Want fast and easy access to all the code in your enterprise? Index and
> search up to 200,000 lines of code with a free copy of Black Duck
> Code Sight - the same software that powers the world's largest code
> search on Ohloh, the Black Duck Open Hub! Try it now.
> http://p.sf.net/sfu/bds
> Firebird-Devel mailing list, web interface at 
> https://lists.sourceforge.net/lists/listinfo/firebird-devel



-- 
Roman Simakov

------------------------------------------------------------------------------
Want fast and easy access to all the code in your enterprise? Index and
search up to 200,000 lines of code with a free copy of Black Duck
Code Sight - the same software that powers the world's largest code
search on Ohloh, the Black Duck Open Hub! Try it now.
http://p.sf.net/sfu/bds
Firebird-Devel mailing list, web interface at 
https://lists.sourceforge.net/lists/listinfo/firebird-devel

Reply via email to