https://codereview.chromium.org/724023002/diff/1/src/api.cc
File src/api.cc (right):
https://codereview.chromium.org/724023002/diff/1/src/api.cc#newcode1759
src/api.cc:1759: source->cached_data->rejected = (script_data == NULL);
I find this a bit weird...
- I expected ..->rejected to be set at the location where the
cached_data was actually rejected.
- Instead, that code deletes the reference to cached_data, but not the
cached_data object.
- Presence of cached_data is then treated as an error code of sorts.
- This would also trigger if has_pending_execution.
(See comment above.)
I'm uneasy about this, but, honestly, given the current code structure I
don't see a super elegant way around this, so I'm a bit unsure on what
to advise...
https://codereview.chromium.org/724023002/diff/1/src/api.cc#newcode1761
src/api.cc:1761: delete script_data;
If script_data was nullified along the way, this is a noop. Who deletes
it then?
https://codereview.chromium.org/724023002/diff/1/src/parser.h
File src/parser.h (right):
https://codereview.chromium.org/724023002/diff/1/src/parser.h#newcode68
src/parser.h:68: *cached_data = NULL;
Memory leak?
Who owns/deletes (*cached_data)?
https://codereview.chromium.org/724023002/
--
--
v8-dev mailing list
v8-dev@googlegroups.com
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to v8-dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.