diff --git a/src/api/mps.c b/src/api/mps.c
index 86cbd13..dba799d 100644
--- a/src/api/mps.c
+++ b/src/api/mps.c
@@ -707,12 +707,12 @@ blnk: {  /* new RANGES vector */
                csa->P->row[i]->name);
          else if (type == GLP_LO)
          {  rhs = csa->P->row[i]->lb;
-            glp_set_row_bnds(csa->P, i, rhs == 0.0 ? GLP_FX : GLP_DB,
+            glp_set_row_bnds(csa->P, i, rng == 0.0 ? GLP_FX : GLP_DB,
                rhs, rhs + fabs(rng));
          }
          else if (type == GLP_UP)
          {  rhs = csa->P->row[i]->ub;
-            glp_set_row_bnds(csa->P, i, rhs == 0.0 ? GLP_FX : GLP_DB,
+            glp_set_row_bnds(csa->P, i, rng == 0.0 ? GLP_FX : GLP_DB,
                rhs - fabs(rng), rhs);
          }
          else if (type == GLP_FX)
