[BGPCEP-484] get restart time from open message error Created: 18/Jun/16  Updated: 03/Mar/19  Resolved: 18/Jul/16

Status: Resolved
Project: bgpcep
Component/s: BGP
Affects Version/s: Bugzilla Migration
Fix Version/s: Bugzilla Migration

Type: Bug
Reporter: dongfang chen Assignee: Ajay L
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Operating System: All
Platform: All


External issue ID: 6084

 Description   

in class GracefulCapabilityHandler method parseCapability.
final int flagBits = (buffer.getByte(0) >> RESTART_FLAGS_SIZE);
cb.setRestartFlags(new RestartFlags((flagBits & Byte.SIZE) != 0));

final int timer = ((buffer.readUnsignedByte() & TIMER_TOPBITS_MASK) << RESTART_FLAGS_SIZE) + buffer.readUnsignedByte();
cb.setRestartTime(timer);

get restart time ,high byte value must left shift one byte length.
in code ,only shift
private static final int RESTART_FLAGS_SIZE = 4;



 Comments   
Comment by Ajay L [ 12/Jul/16 ]

master: https://git.opendaylight.org/gerrit/#/c/41730/

Comment by Milos Fabian [ 18/Jul/16 ]

stable/beryllium: https://git.opendaylight.org/gerrit/#/c/41915

Generated at Wed Feb 07 19:13:12 UTC 2024 using Jira 8.20.10#820010-sha1:ace47f9899e9ee25d7157d59aa17ab06aee30d3d.