GoogleCloudPlatform / GoogleCloudPlatform/cpp-samples

Fix avro_read segfault

Open
#346 3 comments 0 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
178
Forks
114
PR merge metrics
No merged PRs in 30d

Description

Current behavior:

❯ .build/avro_read alevenb-test usa_names top10_names
[1] 1002898 segmentation fault .build/avro_read alevenb-test usa_names top10_names

GDB shows:

```

Thread 1 "avro_read" received signal SIGSEGV, Segmentation fault.
0x0000000000000040 in ?? ()
(gdb) bt
#0 0x0000000000000040 in ?? ()
#1 0x00005555556af4c7 in avro::GenericDatum* std::__do_uninit_copy<__gnu_cxx::__normal_iterator > >, avro::GenericDatum*>(__gnu_cxx::__normal_iterator > >, __gnu_cxx::__normal_iterator > >, avro::GenericDatum*) ()
#2 0x00005555556c8109 in avro::makeRecordNode(avro::json::Entity const&, avro::Name const&, std::__cxx11::basic_string, std::allocator > const*, std::map, std::allocator >, avro::json::Entity, std::less, std::alloc--Type for more, q to quit, c to continue without paging--
ator > >, std::allocator, std::allocator > const, avro::json::Entity> > > const&, std::map, std::less, std::allocator > > >&, std::__cxx11::basic_string, std::allocator > const&) ()
#3 0x00005555556c9517 in avro::makeNode(avro::json::Entity const&, std::map, std::less, std::allocator > > >&, std::__cxx11::basic_string, std::allocator > const&) ()
#4 0x00005555556ca9d6 in avro::compileJsonSchemaFromStream(avro::InputStream&) ()
#5 0x00005555556cac52 in avro::compileJsonSchema(std::istream&, avro::ValidSchema&) ()
--Type for more, q to quit, c to continue without paging--
#6 0x00005555556a83bb in main ()
(gdb)
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.