message: Set onClose reason to null when swConnection::websocket_close_reason length is 0
diff: @@ -1686,9 +1686,12 @@ void php_swoole_onClose(swServer *serv, swDataHead *info)
  if (strlen(connection->websocket_close_reason))
  {
  - php_printf("%s\n", connection->websocket_close_reason);
  SW_ZVAL_STRINGL(reason, connection->websocket_close_reason, strlen(connection->websocket_close_reason), 1);
  }
  + else
  + {
  + Z_TYPE_P(reason) = IS_NULL;
  + }
  args[3] = status_code;
  args[4] = reason;
  @@ -1739,9 +1742,12 @@ void php_swoole_onClose(swServer *serv, swDataHead *info)
  if (strlen(connection->websocket_close_reason))
  {
  - php_printf("%s\n", connection->websocket_close_reason);
  SW_ZVAL_STRINGL(reason, connection->websocket_close_reason, strlen(connection->websocket_close_reason), 1);
  }
  + else
  + {
  + Z_TYPE_P(reason) = IS_NULL;
  + }
  args[3] = &status_code;
  args[4] = &reason;
  