Skip to content
This repository was archived by the owner on Aug 8, 2023. It is now read-only.

Testcase replication for invalid array access in collection.update - #15531

Closed
springmeyer wants to merge 1 commit into
masterfrom
testcase_issue_15514
Closed

springmeyer wants to merge 1 commit into
masterfrom
testcase_issue_15514

Conversation

@springmeyer

Copy link
Copy Markdown
Contributor

This is a testcase that replicates the problem in #15514.

When run inside gtest on Mac OS (with master at 2984535):

./build/macos/Debug/mbgl-test --gtest_filter=*.LoadSyncRender

I get:

[ RUN      ] SyncFileSource.LoadSyncRender
unknown file: Failure
C++ exception with description "vector" thrown in the test body.
[  FAILED  ] SyncFileSource.LoadSyncRender (88 ms)

Which replicates the root problem described at #15514.

Rather than an std::out_of_range error being thrown I would expect the call to map.getStyle().loadJSON to succeed (Although in this case I'm using existing test fixtures, so there may be a different, valid error that is thrown by this test once the underlying std::out_of_range bug is fixed and until this test is improved).

@springmeyer springmeyer changed the title Testcase replicate for invalid array access in collection.update Testcase replication for invalid array access in collection.update Aug 31, 2019
@springmeyer

Copy link
Copy Markdown
Contributor Author

One open question: does this crash have anything to do with using a MapObserver::nullObserver()?

I pulled that usage from

Map map(frontend, MapObserver::nullObserver(),
.

/cc @kkaefer @tmpsantos

@kkaefer kkaefer mentioned this pull request Sep 3, 2019
1 task done
@kkaefer

kkaefer commented Sep 3, 2019

Copy link
Copy Markdown
Member

One open question: does this crash have anything to do with using a MapObserver::nullObserver()?

No; the nullObserver merely ignores all events that it gets sent.

@springmeyer

Copy link
Copy Markdown
Contributor Author

closing, this testcase landed in #15548

@springmeyer springmeyer closed this Sep 4, 2019
@springmeyer
springmeyer deleted the testcase_issue_15514 branch September 4, 2019 05:40
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants