Index: src/trusted/service_runtime/nacl_text.c |
diff --git a/src/trusted/service_runtime/nacl_text.c b/src/trusted/service_runtime/nacl_text.c |
index 047ec6c6f51d58317524713f62b2ee3b0a074260..af4dd3753983755fb7d0cc805e3a92ddf2513bf4 100644 |
--- a/src/trusted/service_runtime/nacl_text.c |
+++ b/src/trusted/service_runtime/nacl_text.c |
@@ -624,7 +624,8 @@ static INLINE void NaClTextMapClearCacheIfNeeded(struct NaClApp *nap, |
int32_t NaClTextDyncodeCreate(struct NaClApp *nap, |
uint32_t dest, |
void *code_copy, |
- uint32_t size) { |
+ uint32_t size, |
+ const struct NaClValidationMetadata *metadata) { |
uintptr_t dest_addr; |
uint8_t *mapped_addr; |
int32_t retval = -NACL_ABI_EINVAL; |
@@ -671,7 +672,7 @@ int32_t NaClTextDyncodeCreate(struct NaClApp *nap, |
* See: http://code.google.com/p/nativeclient/issues/detail?id=2566 |
*/ |
if (!nap->skip_validator) { |
- validator_result = NaClValidateCode(nap, dest, code_copy, size); |
+ validator_result = NaClValidateCode(nap, dest, code_copy, size, metadata); |
} else { |
NaClLog(LOG_ERROR, "VALIDATION SKIPPED.\n"); |
validator_result = LOAD_OK; |
@@ -751,7 +752,8 @@ int32_t NaClSysDyncodeCreate(struct NaClAppThread *natp, |
} |
memcpy(code_copy, (uint8_t*) src_addr, size); |
- retval = NaClTextDyncodeCreate(nap, dest, code_copy, size); |
+ /* Unknown data source, no metadata. */ |
+ retval = NaClTextDyncodeCreate(nap, dest, code_copy, size, NULL); |
free(code_copy); |
return retval; |