AbstractHttp2Frame firstFrame = hasHeaderFragmentList.get(0);
DataWrapper allSerializedHeaders = dataGen.emptyWrapper();
for (AbstractHttp2Frame iterFrame : hasHeaderFragmentList) {
allSerializedHeaders = dataGen.chainDataWrappers(allSerializedHeaders, ((HasHeaderFragment) iterFrame).getHeaderFragment());
}
<BUG>((HasHeaderList) firstFrame).setHeaderList(deserializeHeaders(allSerializedHeaders, decoder));
((HasHeaderFragment) firstFrame).setEndHeaders(true); // fake setting end headers</BUG>
frames.add(firstFrame);
hasHeaderFragmentList.clear();
}

AbstractHttp2Frame firstFrame = hasHeaderFragmentList.get(0);
DataWrapper allSerializedHeaders = dataGen.emptyWrapper();
for (AbstractHttp2Frame iterFrame : hasHeaderFragmentList) {
allSerializedHeaders = dataGen.chainDataWrappers(allSerializedHeaders, ((HasHeaderFragment) iterFrame).getHeaderFragment());
}
HeaderDecoding decoding = new HeaderDecoding(decoder);
List<Http2Header> headers = decoding.decode(allSerializedHeaders);
((HasHeaderList) firstFrame).setHeaderList(headers);
((HasHeaderFragment) firstFrame).setEndHeaders(true); // fake setting end headers
frames.add(firstFrame);
hasHeaderFragmentList.clear();
}
