Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue in parsing value ranges #33

Open
nickaein opened this issue Jul 15, 2018 · 2 comments
Open

Issue in parsing value ranges #33

nickaein opened this issue Jul 15, 2018 · 2 comments
Labels

Comments

@nickaein
Copy link

There seems to be an issue in parsing value-range constraints. Consider the following toy MIB:

MY-MIB DEFINITIONS ::= BEGIN

IMPORTS OBJECT-TYPE, Integer32 FROM SNMPv2-SMI;

my-parameter OBJECT-TYPE
	SYNTAX 	Integer32 (100..200)
	MAX-ACCESS  	read-only
	STATUS 	current
	DESCRIPTION "Simple parameter"
	::= { iso 1 }

END

The exitValueConstraint method process the constraints and eventually creates an ValueRangeConstraint instance with lowerbound of 200 and no upperbound. There is possibly an issue inside for loop in determining the presence of low and upper bounds.

@cederberg cederberg added the Bug label Jul 15, 2018
@cederberg
Copy link
Owner

Good catch. Issue is on line 1179 where strictLower should be lower. Must have been tumbled around in one refactoring or another.

@nickaein
Copy link
Author

That seems to take care of it. Thanks for quick update!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants