Code Review
/
aaf
/
authz.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
Merge "major-Extract the assignment out of this expression"
[aaf/authz.git]
/
auth
/
auth-batch
/
src
/
main
/
java
/
org
/
onap
/
aaf
/
auth
/
batch
/
helpers
/
Cred.java
diff --git
a/auth/auth-batch/src/main/java/org/onap/aaf/auth/batch/helpers/Cred.java
b/auth/auth-batch/src/main/java/org/onap/aaf/auth/batch/helpers/Cred.java
index
83638cc
..
6f23c51
100644
(file)
--- a/
auth/auth-batch/src/main/java/org/onap/aaf/auth/batch/helpers/Cred.java
+++ b/
auth/auth-batch/src/main/java/org/onap/aaf/auth/batch/helpers/Cred.java
@@
-3,6
+3,7
@@
* org.onap.aaf
* ===========================================================================
* Copyright (c) 2018 AT&T Intellectual Property. All rights reserved.
* org.onap.aaf
* ===========================================================================
* Copyright (c) 2018 AT&T Intellectual Property. All rights reserved.
+ * Modifications Copyright (C) 2019 IBM.
* ===========================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* ===========================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@
-203,9
+204,10
@@
public class Cred {
}
cred.instances.add(new Instance(type, timestamp, other, written/1000,tag));
}
cred.instances.add(new Instance(type, timestamp, other, written/1000,tag));
- List<Cred> lscd = byNS.get(cred.ns);
+ List<Cred> lscd = byNS.get(cred.ns);
if (lscd==null) {
if (lscd==null) {
- byNS.put(cred.ns, (lscd=new ArrayList<>()));
+ lscd=new ArrayList<>();
+ byNS.put(cred.ns,lscd);
}
boolean found = false;
for (Cred c : lscd) {
}
boolean found = false;
for (Cred c : lscd) {
@@
-271,11
+273,9
@@
public class Cred {
public void inc(int type, Date start, Date expires) {
for (int i=0;i<dates.length-1;++i) {
if (start.before(dates[i])) {
public void inc(int type, Date start, Date expires) {
for (int i=0;i<dates.length-1;++i) {
if (start.before(dates[i])) {
- if (type==CredDAO.CERT_SHA256_RSA) {
- if (start.after(dates[i+1])) {
+ if ((type==CredDAO.CERT_SHA256_RSA)&&(start.after(dates[i+1]))) {
++x509Added[i];
++x509Added[i];
- }
- }
+ }
if (expires.after(dates[i])) {
switch(type) {
case CredDAO.RAW:
if (expires.after(dates[i])) {
switch(type) {
case CredDAO.RAW: