Index: ossp-pkg/var/var.c RCS File: /v/ossp/cvs/ossp-pkg/var/var.c,v rcsdiff -q -kk '-r1.28' '-r1.29' -u '/v/ossp/cvs/ossp-pkg/var/var.c,v' 2>/dev/null --- var.c 2001/11/20 11:46:34 1.28 +++ var.c 2001/11/20 12:22:42 1.29 @@ -907,7 +907,9 @@ return VAR_ERR_OFFSET_LOGIC; if ((data->begin + num2) > data->end) return VAR_ERR_RANGE_OUT_OF_BOUNDS; - if (!tokenbuf_assign(&res, p, (data->begin + num2) - p)) + if (!tokenbuf_assign(&res, p, num2 - num1)) +//FIXME THL: I expect start-end *inclusive* +//FIXME THL: I expect start,len len characters not len-1 return VAR_ERR_OUT_OF_MEMORY; } } Index: ossp-pkg/var/var.pod RCS File: /v/ossp/cvs/ossp-pkg/var/var.pod,v rcsdiff -q -kk '-r1.5' '-r1.6' -u '/v/ossp/cvs/ossp-pkg/var/var.pod,v' 2>/dev/null --- var.pod 2001/11/19 16:15:32 1.5 +++ var.pod 2001/11/20 12:22:42 1.6 @@ -533,15 +533,6 @@ =item ${name:o-} -This operation will cut the range of "start" to "end" out of the -contents of $name and return that. ${name:o3-4} means, for instance, -to return the next 4 charaters starting at position 3 in the string. -Please note that start positions begin at zero (0)! If the "end" range -is left out, as in ${name:o3-}, the operation will return the string -starting at position 3 until the end. - -=item ${name:o,} - This operation will cut the string starting at position "start" to ending position "end" out of the contents of $name and return that. Please note that the character at position "end" is not included in @@ -552,6 +543,18 @@ as in ${name:o3,}, the operation will return the string starting at position 3 until the end. +//FIXME THL: I expect start-end *inclusive* +//FIXME THL: I expect start,len len characters not len-1 + +=item ${name:o,} + +This operation will cut the range of "start" to "end" out of the +contents of $name and return that. ${name:o3-4} means, for instance, +to return the next 4 charaters starting at position 3 in the string. +Please note that start positions begin at zero (0)! If the "end" range +is left out, as in ${name:o3-}, the operation will return the string +starting at position 3 until the end. + =item ${name:s///[gti]} This operation will perform a search-and-replace operation on the