Open cdietrich opened 2 years ago
our TypeAdapter(Factories) dont check if the (token) type passed into public <T> TypeAdapter<T> create(Gson gson, TypeToken<T> type) { matches the type the adapter is for.
public <T> TypeAdapter<T> create(Gson gson, TypeToken<T> type) {
when testing with
GsonBuilder builder = new GsonBuilder(); builder.registerTypeAdapterFactory(new RestartArgumentsTypeAdapterFactory()); Gson gson = builder.create(); XXXX object = gson.fromJson("{\"noDebug\":true}", ELEMENT_TYPE.getType());
this may lead to stackoverflows
our TypeAdapter(Factories) dont check if the (token) type passed into
public <T> TypeAdapter<T> create(Gson gson, TypeToken<T> type) {
matches the type the adapter is for.when testing with
this may lead to stackoverflows