mir_surface_is_valid(NULL) crashes instead of returning false
Bug #1248474 reported by
Daniel van Vugt
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Mir |
Fix Released
|
Medium
|
Chris Halse Rogers | ||
mir (Ubuntu) |
Fix Released
|
Medium
|
Unassigned |
Bug Description
I have a test case where I encountered:
mir_
and it crashes with SIGSEGV. Obviously the surface is not valid and we should be returning false instead of crashing.
The cause is:
int mir_surface_
{
return surface-
}
Related branches
lp:~raof/mir/robust-surface-is-valid
- Andreas Pokorny (community): Approve
- Alberto Aguirre (community): Approve
- Robert Carr (community): Approve
- PS Jenkins bot (community): Approve (continuous-integration)
-
Diff: 136 lines (+46/-6)5 files modifiedsrc/client/mir_surface.cpp (+16/-4)
src/client/mir_surface.h (+2/-1)
src/client/mir_surface_api.cpp (+1/-1)
tests/unit-tests/client/test_client.cpp (+13/-0)
tests/unit-tests/client/test_client_mir_surface.cpp (+14/-0)
summary: |
- mir_surface_is_valid crashes if passed an invalid pointer + mir_surface_is_valid(NULL) crashes instead of returning false |
tags: | added: clientapi |
Changed in mir: | |
status: | Triaged → In Progress |
assignee: | nobody → Chris Halse Rogers (raof) |
milestone: | none → 0.2.0 |
Changed in mir: | |
status: | In Progress → Fix Committed |
Changed in mir: | |
status: | Fix Committed → Fix Released |
Changed in mir (Ubuntu): | |
importance: | Undecided → Medium |
status: | New → Fix Released |
To post a comment you must log in.