| Index: mojo/public/cpp/bindings/struct_ptr.h
|
| diff --git a/mojo/public/cpp/bindings/struct_ptr.h b/mojo/public/cpp/bindings/struct_ptr.h
|
| index 04a8130fc65ba31edc1d7bd83ef87ea75962b6d4..b47a1ed0d039e81de3ec19233ac648f5280c2243 100644
|
| --- a/mojo/public/cpp/bindings/struct_ptr.h
|
| +++ b/mojo/public/cpp/bindings/struct_ptr.h
|
| @@ -150,7 +150,7 @@ class InlinedStructPtr {
|
| MOJO_DCHECK(!is_null_);
|
| return &value_;
|
| }
|
| - Struct* get() const { return &value_; }
|
| + Struct* get() const { return is_null() ? nullptr : &value_; }
|
|
|
| void Swap(InlinedStructPtr* other) {
|
| std::swap(value_, other->value_);
|
|
|