Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 /* | 1 /* |
| 2 * Copyright (c) 2012 The Native Client Authors. All rights reserved. | 2 * Copyright (c) 2012 The Native Client Authors. All rights reserved. |
| 3 * Use of this source code is governed by a BSD-style license that can be | 3 * Use of this source code is governed by a BSD-style license that can be |
| 4 * found in the LICENSE file. | 4 * found in the LICENSE file. |
| 5 */ | 5 */ |
| 6 | 6 |
| 7 #include "native_client/src/shared/platform/nacl_log.h" | 7 #include "native_client/src/shared/platform/nacl_log.h" |
| 8 #include "native_client/src/trusted/service_runtime/sel_ldr.h" | 8 #include "native_client/src/trusted/service_runtime/sel_ldr.h" |
| 9 #include "native_client/src/trusted/validator/ncvalidate.h" | 9 #include "native_client/src/trusted/validator/ncvalidate.h" |
| 10 | 10 |
| (...skipping 16 matching lines...) Expand all Loading... | |
| 27 } | 27 } |
| 28 } | 28 } |
| 29 | 29 |
| 30 typedef NaClValidationStatus (*ValidateFunc) ( | 30 typedef NaClValidationStatus (*ValidateFunc) ( |
| 31 uintptr_t, uint8_t*, size_t, int, int, | 31 uintptr_t, uint8_t*, size_t, int, int, |
| 32 const NaClCPUFeatures*, struct NaClValidationCache*); | 32 const NaClCPUFeatures*, struct NaClValidationCache*); |
| 33 | 33 |
| 34 static ValidateFunc NaClSelectValidator(struct NaClApp *nap) { | 34 static ValidateFunc NaClSelectValidator(struct NaClApp *nap) { |
| 35 ValidateFunc ret = NACL_SUBARCH_NAME(ApplyValidator, | 35 ValidateFunc ret = NACL_SUBARCH_NAME(ApplyValidator, |
| 36 NACL_TARGET_ARCH, NACL_TARGET_SUBARCH); | 36 NACL_TARGET_ARCH, NACL_TARGET_SUBARCH); |
| 37 #ifdef __arm__ | 37 #if defined(__arm__) || !defined (NACL_STANDALONE) |
|
Mark Seaborn
2012/04/25 16:48:43
No space after 'defined'. Can you add a comment h
pasko-google - do not use
2012/04/25 17:32:03
Done.
| |
| 38 UNREFERENCED_PARAMETER(nap); | 38 UNREFERENCED_PARAMETER(nap); |
| 39 #else | 39 #else |
| 40 if (nap->enable_dfa_validator) { | 40 if (nap->enable_dfa_validator) { |
| 41 ret = NACL_SUBARCH_NAME(ApplyDfaValidator, | 41 ret = NACL_SUBARCH_NAME(ApplyDfaValidator, |
| 42 NACL_TARGET_ARCH, NACL_TARGET_SUBARCH); | 42 NACL_TARGET_ARCH, NACL_TARGET_SUBARCH); |
| 43 } | 43 } |
| 44 #endif | 44 #endif |
| 45 return ret; | 45 return ret; |
| 46 } | 46 } |
| 47 | 47 |
| (...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 164 NaClLog(LOG_ERROR, | 164 NaClLog(LOG_ERROR, |
| 165 "Run sel_ldr in debug mode to ignore validation failure.\n"); | 165 "Run sel_ldr in debug mode to ignore validation failure.\n"); |
| 166 NaClLog(LOG_ERROR, | 166 NaClLog(LOG_ERROR, |
| 167 "Run ncval <module-name> for validation error details.\n"); | 167 "Run ncval <module-name> for validation error details.\n"); |
| 168 rcode = LOAD_VALIDATION_FAILED; | 168 rcode = LOAD_VALIDATION_FAILED; |
| 169 } | 169 } |
| 170 } | 170 } |
| 171 } | 171 } |
| 172 return rcode; | 172 return rcode; |
| 173 } | 173 } |
| OLD | NEW |