8325361: Make sun.net.www.MessageHeader final

Reviewed-by: dfuchs
This commit is contained in:
Korov 2024-03-01 10:58:59 +00:00 committed by Daniel Fuchs
parent 5b75199769
commit e85265abc2

@ -1,5 +1,5 @@
/*
* Copyright (c) 1995, 2023, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1995, 2024, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -40,17 +40,15 @@ import java.util.*;
the header that don't have a valid key, but do have
a value (this isn't legal according to the standard,
but lines like this are everywhere). */
public
class MessageHeader {
private String keys[];
private String values[];
public final class MessageHeader {
private String[] keys;
private String[] values;
private int nkeys;
public MessageHeader () {
grow();
}
@SuppressWarnings("this-escape")
public MessageHeader (InputStream is) throws java.io.IOException {
parseHeader(is);
}