Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix debug mode compile error #5

Merged
merged 1 commit into from
Nov 21, 2019
Merged

Fix debug mode compile error #5

merged 1 commit into from
Nov 21, 2019

Conversation

wangxiyuan
Copy link

When compile frocksdb-5.17.2 with DEBUG mode(i.e. DEBUG=1), an error occured:

In file included from /usr/include/c++/5/cassert:43:0,
                 from ./include/rocksdb/compaction_filter.h:11,
                 from ./java/./rocksjni/compaction_filter_factory_jnicallback.h:15,
                 from ./java/./rocksjni/portal.h:31,
                 from java/rocksjni/loggerjnicallback.cc:14:
java/rocksjni/loggerjnicallback.cc: In member function ‘virtual void rocksdb::LoggerJniCallback::Logv(rocksdb::InfoLogLevel, const char*, va_list)’:
java/rocksjni/loggerjnicallback.cc:134:18: error: invalid operands of types ‘va_list {aka __va_list}’ and ‘std::nullptr_t’ to binary ‘operator!=’
     assert(ap != nullptr);

This PR fixed this error so that frocksdb can be compiled with DEBUG mode. It will make sure the jtest can be ran correctly as well.

This is a cherry-pick from rocksdb, see: facebook/rocksdb#5836

Myasuka referenced this pull request in Myasuka/flink Nov 18, 2019
Bump version to io.github.myasuka frocksdbjni 5.17.2-artisans-3.0
This includes dataArtisans/frocksdb#5 and dataArtisans/frocksdb#4
Myasuka referenced this pull request in Myasuka/flink-1 Nov 18, 2019
Bump version to io.github.myasuka frocksdbjni 5.17.2-artisans-3.0
This includes dataArtisans/frocksdb#5 and dataArtisans/frocksdb#4
Myasuka referenced this pull request in Myasuka/flink-1 Nov 18, 2019
Bump version to io.github.myasuka frocksdbjni 5.17.2-artisans-3.0
This includes dataArtisans/frocksdb#5 and dataArtisans/frocksdb#4
Myasuka referenced this pull request in Myasuka/flink-1 Nov 21, 2019
Bump version to io.github.myasuka frocksdbjni 5.17.2-artisans-3.0
This includes dataArtisans/frocksdb#5 and dataArtisans/frocksdb#4
@StephanEwen StephanEwen merged commit 5a11eb2 into ververica:FRocksDB-5.17.2 Nov 21, 2019
rkhachatryan pushed a commit that referenced this pull request Jan 30, 2024
Summary:
I must have chosen trimming before frame 8 based on assertion failures, but that trims too many frame for a general segfault. So this changes to start printing at frame 4, as in this example where I've seeded a null deref:

```
Received signal 11 (Segmentation fault)
Invoking LLDB for stack trace...
Process 873208 stopped
* thread #1, name = 'db_stress', stop reason = signal SIGSTOP
    frame #0: 0x00007fb1fe8f1033 libc.so.6`__GI___wait4(pid=873478, stat_loc=0x00007fb1fb114030, options=0, usage=0x0000000000000000) at wait4.c:30:10
  thread #2, name = 'rocksdb:low', stop reason = signal SIGSTOP
    frame #0: 0x00007fb1fe8972a1 libc.so.6`__GI___futex_abstimed_wait_cancelable64 at futex-internal.c:57:12
Executable module set to "/data/users/peterd/rocksdb/db_stress".
Architecture set to: x86_64-unknown-linux-gnu.
True
frame #4: 0x00007fb1fe844540 libc.so.6`__restore_rt at libc_sigaction.c:13
frame #5: 0x0000000000608514 db_stress`rocksdb::StressTest::InitDb(rocksdb::SharedState*) at db_stress_test_base.cc:345:18
frame #6: 0x0000000000585d62 db_stress`rocksdb::RunStressTestImpl(rocksdb::SharedState*) at db_stress_driver.cc:84:17
frame #7: 0x000000000058dd69 db_stress`rocksdb::RunStressTest(shared=0x00006120000001c0) at db_stress_driver.cc:266:34
frame #8: 0x0000000000453b34 db_stress`rocksdb::db_stress_tool(int, char**) at db_stress_tool.cc:370:20
...
```

Pull Request resolved: facebook/rocksdb#12101

Test Plan: manual (see above)

Reviewed By: ajkr

Differential Revision: D51593217

Pulled By: pdillinger

fbshipit-source-id: 4a71eb8e516edbc32e682f9537bc77d073a7b4ed
fredia pushed a commit to fredia/frocksdb that referenced this pull request May 31, 2024
Zakelly pushed a commit to Zakelly/frocksdb that referenced this pull request Sep 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants