[jira] [Work logged] (NUMBERS-99) Fraction.add(int) and Fraction.subtract(int) ignore risk of integer overflow

2019-05-24 Thread ASF GitHub Bot (JIRA)


 [ 
https://issues.apache.org/jira/browse/NUMBERS-99?focusedWorklogId=247980=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-247980
 ]

ASF GitHub Bot logged work on NUMBERS-99:
-

Author: ASF GitHub Bot
Created on: 24/May/19 10:46
Start Date: 24/May/19 10:46
Worklog Time Spent: 10m 
  Work Description: Schamschi commented on pull request #34: [NUMBERS-99] 
Implement integer overflow checks
URL: https://github.com/apache/commons-numbers/pull/34
 
 
   
 

This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 247980)
Time Spent: 20m  (was: 10m)

> Fraction.add(int) and Fraction.subtract(int) ignore risk of integer overflow
> 
>
> Key: NUMBERS-99
> URL: https://issues.apache.org/jira/browse/NUMBERS-99
> Project: Commons Numbers
>  Issue Type: Bug
>  Components: fraction
>Reporter: Heinrich Bohne
>Priority: Minor
>  Time Spent: 20m
>  Remaining Estimate: 0h
>
> The methods {{add(int)}} and {{subtract(int)}} in the class 
> {{org.apache.commons.numbers.fraction.Fraction}} do not take into account the 
> risk of an integer overflow. For example, (2​^31^ - 1)/2 + 1 = (2​^31^ + 
> 1)/2, so the numerator overflows an {{int}}, but when calculated with 
> {{Fraction.add(int)}}, the method still returns normally.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Work logged] (NUMBERS-99) Fraction.add(int) and Fraction.subtract(int) ignore risk of integer overflow

2019-05-19 Thread ASF GitHub Bot (JIRA)


 [ 
https://issues.apache.org/jira/browse/NUMBERS-99?focusedWorklogId=244657=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-244657
 ]

ASF GitHub Bot logged work on NUMBERS-99:
-

Author: ASF GitHub Bot
Created on: 19/May/19 12:36
Start Date: 19/May/19 12:36
Worklog Time Spent: 10m 
  Work Description: Schamschi commented on pull request #34: [NUMBERS-99] 
Implement integer overflow checks
URL: https://github.com/apache/commons-numbers/pull/34
 
 
   Guard Fraction.add(int) and Fraction.subtract(int) against integer overflow 
and add some unit tests.
 

This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 244657)
Time Spent: 10m
Remaining Estimate: 0h

> Fraction.add(int) and Fraction.subtract(int) ignore risk of integer overflow
> 
>
> Key: NUMBERS-99
> URL: https://issues.apache.org/jira/browse/NUMBERS-99
> Project: Commons Numbers
>  Issue Type: Bug
>  Components: fraction
>Reporter: Heinrich Bohne
>Priority: Minor
>  Time Spent: 10m
>  Remaining Estimate: 0h
>
> The methods {{add(int)}} and {{subtract(int)}} in the class 
> {{org.apache.commons.numbers.fraction.Fraction}} do not take into account the 
> risk of an integer overflow. For example, (2​^31^ - 1)/2 + 1 = (2​^31^ + 
> 1)/2, so the numerator overflows an {{int}}, but when calculated with 
> {{Fraction.add(int)}}, the method still returns normally.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)