| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
| 3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
| 4 // met: | 4 // met: |
| 5 // | 5 // |
| 6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
| 7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
| 8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
| 9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
| 10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
| (...skipping 451 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 462 JSFunction* fun = JSFunction::cast(f); | 462 JSFunction* fun = JSFunction::cast(f); |
| 463 Object* perhaps_context = fun->unchecked_context(); | 463 Object* perhaps_context = fun->unchecked_context(); |
| 464 if (perhaps_context->IsHeapObject() && | 464 if (perhaps_context->IsHeapObject() && |
| 465 heap->Contains(HeapObject::cast(perhaps_context)) && | 465 heap->Contains(HeapObject::cast(perhaps_context)) && |
| 466 perhaps_context->IsContext()) { | 466 perhaps_context->IsContext()) { |
| 467 Context* context = fun->context(); | 467 Context* context = fun->context(); |
| 468 if (!heap->Contains(context)) { | 468 if (!heap->Contains(context)) { |
| 469 Add("(Function context is outside heap)\n"); | 469 Add("(Function context is outside heap)\n"); |
| 470 return; | 470 return; |
| 471 } | 471 } |
| 472 Object* token = context->native_context()->security_token(); | 472 Object* token = context->global_context()->security_token(); |
| 473 if (token != isolate->string_stream_current_security_token()) { | 473 if (token != isolate->string_stream_current_security_token()) { |
| 474 Add("Security context: %o\n", token); | 474 Add("Security context: %o\n", token); |
| 475 isolate->set_string_stream_current_security_token(token); | 475 isolate->set_string_stream_current_security_token(token); |
| 476 } | 476 } |
| 477 } else { | 477 } else { |
| 478 Add("(Function context is corrupt)\n"); | 478 Add("(Function context is corrupt)\n"); |
| 479 } | 479 } |
| 480 } | 480 } |
| 481 | 481 |
| 482 | 482 |
| (...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 580 | 580 |
| 581 // Only grow once to the maximum allowable size. | 581 // Only grow once to the maximum allowable size. |
| 582 char* NoAllocationStringAllocator::grow(unsigned* bytes) { | 582 char* NoAllocationStringAllocator::grow(unsigned* bytes) { |
| 583 ASSERT(size_ >= *bytes); | 583 ASSERT(size_ >= *bytes); |
| 584 *bytes = size_; | 584 *bytes = size_; |
| 585 return space_; | 585 return space_; |
| 586 } | 586 } |
| 587 | 587 |
| 588 | 588 |
| 589 } } // namespace v8::internal | 589 } } // namespace v8::internal |
| OLD | NEW |