This is reusing a parameter for slightly dubious ends.  It is liable to cause confusion - since srcLen is no longer the length of the source string.