summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/erasurecode_preprocessing.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/erasurecode_preprocessing.c b/src/erasurecode_preprocessing.c
index 64c7edd..8492184 100644
--- a/src/erasurecode_preprocessing.c
+++ b/src/erasurecode_preprocessing.c
@@ -240,7 +240,7 @@ int get_fragment_partition(
*/
for (i = 0; i < num_fragments; i++) {
index = get_fragment_idx(fragments[i]);
- if (index < 0){
+ if (index < 0 || index > (k + m)) {
return -EBADHEADER;
}
if (index < k) {