Mercurial > hg > graal-compiler
comparison src/share/vm/services/diagnosticArgument.cpp @ 7627:c73c3f2c5b3b
Merge
author | acorn |
---|---|
date | Mon, 21 Jan 2013 16:11:24 -0500 |
parents | 79f492f184d0 203f64878aab |
children | b0301c02f38e |
comparison
equal
deleted
inserted
replaced
7622:617b18aadb33 | 7627:c73c3f2c5b3b |
---|---|
1 /* | 1 /* |
2 * Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. | 2 * Copyright (c) 2011, 2013 Oracle and/or its affiliates. All rights reserved. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. | 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 * | 4 * |
5 * This code is free software; you can redistribute it and/or modify it | 5 * This code is free software; you can redistribute it and/or modify it |
6 * under the terms of the GNU General Public License version 2 only, as | 6 * under the terms of the GNU General Public License version 2 only, as |
7 * published by the Free Software Foundation. | 7 * published by the Free Software Foundation. |
84 } | 84 } |
85 } | 85 } |
86 | 86 |
87 template <> void DCmdArgument<jlong>::parse_value(const char* str, | 87 template <> void DCmdArgument<jlong>::parse_value(const char* str, |
88 size_t len, TRAPS) { | 88 size_t len, TRAPS) { |
89 if (str == NULL || sscanf(str, INT64_FORMAT, &_value) != 1) { | 89 if (str == NULL || sscanf(str, JLONG_FORMAT, &_value) != 1) { |
90 THROW_MSG(vmSymbols::java_lang_IllegalArgumentException(), | 90 THROW_MSG(vmSymbols::java_lang_IllegalArgumentException(), |
91 "Integer parsing error in diagnostic command arguments\n"); | 91 "Integer parsing error in diagnostic command arguments\n"); |
92 } | 92 } |
93 } | 93 } |
94 | 94 |
169 if (str == NULL) { | 169 if (str == NULL) { |
170 THROW_MSG(vmSymbols::java_lang_IllegalArgumentException(), | 170 THROW_MSG(vmSymbols::java_lang_IllegalArgumentException(), |
171 "Integer parsing error nanotime value: syntax error"); | 171 "Integer parsing error nanotime value: syntax error"); |
172 } | 172 } |
173 | 173 |
174 int argc = sscanf(str, INT64_FORMAT , &_value._time); | 174 int argc = sscanf(str, JLONG_FORMAT, &_value._time); |
175 if (argc != 1) { | 175 if (argc != 1) { |
176 THROW_MSG(vmSymbols::java_lang_IllegalArgumentException(), | 176 THROW_MSG(vmSymbols::java_lang_IllegalArgumentException(), |
177 "Integer parsing error nanotime value: syntax error"); | 177 "Integer parsing error nanotime value: syntax error"); |
178 } | 178 } |
179 size_t idx = 0; | 179 size_t idx = 0; |