message: fix for substrings
diff: @@ -26,24 +26,28 @@ void substring_function(Vector inputs[], size_t input_count, Vector &result) {
  VectorOperations::TernaryExec(
  input, offset, length, result,
  [&](size_t input_index, size_t offset_index, size_t length_index, size_t result_index) {
  - auto input = input_data[input_index];
  + auto input_string = input_data[input_index];
  auto offset = offset_data[offset_index] - 1;
  auto length = length_data[length_index];
  + if (input.nullmask[input_index]) {
  + return;
  + }
  +
  // create the output string
  char output[length + 1];
  int input_offset = 0;
  - while (input[input_offset] && input_offset < offset) {
  + while (input_string[input_offset] && input_offset < offset) {
  input_offset++;
  }
  - if (!input[input_offset]) {
  + if (!input_string[input_offset]) {
  // out of range, return empty string
  output[0] = '\0';
  } else {
  // now limit the string
  size_t write_offset = 0;
  - while (input[input_offset + write_offset] && write_offset < length) {
  - output[write_offset] = input[input_offset + write_offset];
  + while (input_string[input_offset + write_offset] && write_offset < length) {
  + output[write_offset] = input_string[input_offset + write_offset];
  write_offset++;
  }
  output[write_offset] = '\0';
  