[jira] [Commented] (FLINK-4638) Fix exception message for MemorySegment

2016-09-20 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/FLINK-4638?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15506668#comment-15506668
 ] 

ASF GitHub Bot commented on FLINK-4638:
---

Github user asfgit closed the pull request at:

https://github.com/apache/flink/pull/2515


> Fix exception message for MemorySegment
> ---
>
> Key: FLINK-4638
> URL: https://issues.apache.org/jira/browse/FLINK-4638
> Project: Flink
>  Issue Type: Improvement
>  Components: Core
>Affects Versions: 2.0.0, 1.1.2, 1.1.3
>Reporter: Liwei Lin
>Priority: Trivial
>
> Please see the code snip below:
> {code:title=MemorySegment.java|borderStyle=solid}
> if (offHeapAddress >= Long.MAX_VALUE - Integer.MAX_VALUE) {
>   throw new IllegalArgumentException("Segment initialized with too large 
> address: " + address // here address has not been initialized yet; should 
> really be offHeapAddress 
>   + " ; Max allowed address is " + (Long.MAX_VALUE - Integer.MAX_VALUE - 
> 1));
> }
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (FLINK-4638) Fix exception message for MemorySegment

2016-09-20 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/FLINK-4638?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15506478#comment-15506478
 ] 

ASF GitHub Bot commented on FLINK-4638:
---

Github user greghogan commented on the issue:

https://github.com/apache/flink/pull/2515
  
Thanks for reporting and fixing! Merging ...


> Fix exception message for MemorySegment
> ---
>
> Key: FLINK-4638
> URL: https://issues.apache.org/jira/browse/FLINK-4638
> Project: Flink
>  Issue Type: Improvement
>  Components: Core
>Affects Versions: 2.0.0, 1.1.2, 1.1.3
>Reporter: Liwei Lin
>Priority: Trivial
>
> Please see the code snip below:
> {code:title=MemorySegment.java|borderStyle=solid}
> if (offHeapAddress >= Long.MAX_VALUE - Integer.MAX_VALUE) {
>   throw new IllegalArgumentException("Segment initialized with too large 
> address: " + address // here address has not been initialized yet; should 
> really be offHeapAddress 
>   + " ; Max allowed address is " + (Long.MAX_VALUE - Integer.MAX_VALUE - 
> 1));
> }
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (FLINK-4638) Fix exception message for MemorySegment

2016-09-20 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/FLINK-4638?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15505773#comment-15505773
 ] 

ASF GitHub Bot commented on FLINK-4638:
---

Github user lw-lin commented on a diff in the pull request:

https://github.com/apache/flink/pull/2515#discussion_r79544108
  
--- Diff: 
flink-core/src/main/java/org/apache/flink/core/memory/MemorySegment.java ---
@@ -161,7 +161,7 @@
}
if (offHeapAddress >= Long.MAX_VALUE - Integer.MAX_VALUE) {
// this is necessary to make sure the collapsed checks 
are safe against numeric overflows
-   throw new IllegalArgumentException("Segment initialized 
with too large address: " + address
--- End diff --

here `address` has not been initialized yet; should really be 
`offHeapAddress`


> Fix exception message for MemorySegment
> ---
>
> Key: FLINK-4638
> URL: https://issues.apache.org/jira/browse/FLINK-4638
> Project: Flink
>  Issue Type: Improvement
>  Components: Core
>Affects Versions: 2.0.0, 1.1.2, 1.1.3
>Reporter: Liwei Lin
>Priority: Trivial
>
> Please see the code snip below:
> {code:title=MemorySegment.java|borderStyle=solid}
> if (offHeapAddress >= Long.MAX_VALUE - Integer.MAX_VALUE) {
>   throw new IllegalArgumentException("Segment initialized with too large 
> address: " + address // here address has not been initialized yet; should 
> really be offHeapAddress 
>   + " ; Max allowed address is " + (Long.MAX_VALUE - Integer.MAX_VALUE - 
> 1));
> }
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (FLINK-4638) Fix exception message for MemorySegment

2016-09-20 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/FLINK-4638?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15505769#comment-15505769
 ] 

ASF GitHub Bot commented on FLINK-4638:
---

GitHub user lw-lin opened a pull request:

https://github.com/apache/flink/pull/2515

[FLINK-4638] Fix exception message for MemorySegment



You can merge this pull request into a Git repository by running:

$ git pull https://github.com/lw-lin/flink fix-msg

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/flink/pull/2515.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #2515


commit 825576c518e83898beaee16ebe304201432ce425
Author: Liwei Lin 
Date:   2016-09-20T06:35:28Z

[FLINK-4638] Fix exception message for MemorySegment




> Fix exception message for MemorySegment
> ---
>
> Key: FLINK-4638
> URL: https://issues.apache.org/jira/browse/FLINK-4638
> Project: Flink
>  Issue Type: Improvement
>  Components: Core
>Affects Versions: 2.0.0, 1.1.2, 1.1.3
>Reporter: Liwei Lin
>Priority: Trivial
>
> Please see the code snip below:
> {code:title=MemorySegment.java|borderStyle=solid}
> if (offHeapAddress >= Long.MAX_VALUE - Integer.MAX_VALUE) {
>   throw new IllegalArgumentException("Segment initialized with too large 
> address: " + address // here address has not been initialized yet; should 
> really be offHeapAddress 
>   + " ; Max allowed address is " + (Long.MAX_VALUE - Integer.MAX_VALUE - 
> 1));
> }
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)