Return INTERNAL_ERROR if QuicErrorCodeToTransportErrorCode() is called with invalid
QuicErrorCode.  This should never happen, because QuicErrorCodeToTransportErrorCode is only called for serializing locally initiated CONNECTION_CLOSE frames, with locally specified QuicErrorCodes.

Note that previous return value {false, NO_IETF_QUIC_ERROR} is invalid, because
NO_IETF_QUIC_ERROR is a transport error code with value 0x0, but false means
application error code, and there is no defined application error code with this
value.  (HTTP/3's H3_NO_ERROR has value 0x100.)

gfe-relnote: Behavior change in IETF QUIC only, protected by gfe2_reloadable_flag_quic_enable_version_draft_25_v3 and gfe2_reloadable_flag_quic_enable_version_draft_27.
PiperOrigin-RevId: 305871445
Change-Id: I5509fb42ca8dd79e9963a8d6ef7c0ebba93c73b3
diff --git a/quic/core/quic_error_codes.cc b/quic/core/quic_error_codes.cc
index cea484e..ea50e0b 100644
--- a/quic/core/quic_error_codes.cc
+++ b/quic/core/quic_error_codes.cc
@@ -574,8 +574,8 @@
     case QUIC_LAST_ERROR:
       return {false, static_cast<uint64_t>(QUIC_LAST_ERROR)};
   }
-  // If it's an unknown code, indicate it's an application error code.
-  return {true, static_cast<uint64_t>(NO_IETF_QUIC_ERROR)};
+  // This function should not be called with unknown error code.
+  return {true, static_cast<uint64_t>(INTERNAL_ERROR)};
 }
 
 #undef RETURN_STRING_LITERAL  // undef for jumbo builds