115 while (read_len > 1 && key_data[read_len - 1] == '\n') {
116 --read_len;
117 }
118 memset(retKeyBuff, 0, buffSize);
CID 1508997: Out-of-bounds access (OVERRUN) [[select issue](https://scan6.scan.coverity.com/defectInstanceId=34625595&fileInstanceId=157339969&mergedDefectId=1508997)]
CID 1508982 (#1 of 1): Argument cannot be negative (NEGATIVE_RETURNS)
6. negative_returns: read_len is passed to a parameter that cannot be negative.
119 strncpy(retKeyBuff, key_data.c_str(), read_len);
120 retval = key_data.length();
121 }