mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-08-11 02:05:39 +02:00
[268830] - fixing the case when value string is empty or null
This commit is contained in:
parent
e659686dd8
commit
62474d01f8
1 changed files with 3 additions and 4 deletions
|
@ -43,10 +43,9 @@ public class ArrayValue extends DerivedValue implements ICDIArrayValue, ICDIPoin
|
|||
*/
|
||||
public ArrayValue(Variable v, String hexAddress) {
|
||||
super(v);
|
||||
if (hexAddress == null) {
|
||||
return;
|
||||
}
|
||||
if (hexAddress.startsWith("0x") || hexAddress.startsWith("0X")) {
|
||||
if (hexAddress == null || hexAddress.trim().length()==0) {
|
||||
this.hexAddress = "0";
|
||||
} else if (hexAddress.startsWith("0x") || hexAddress.startsWith("0X")) {
|
||||
this.hexAddress = hexAddress.substring(2);
|
||||
} else {
|
||||
this.hexAddress = hexAddress;
|
||||
|
|
Loading…
Add table
Reference in a new issue