Skip to content

Commit

Permalink
TEZ-4584: TezUtilsInternal.readUserSpecifiedTezConfiguration throws c…
Browse files Browse the repository at this point in the history
…om.google.protobuf.CodedInputStream exception
  • Loading branch information
liujiayi771 committed Oct 31, 2024
1 parent 607b2bc commit 0712849
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@
import java.util.zip.Inflater;

import com.google.protobuf.ByteString;
import com.google.protobuf.CodedInputStream;
import com.google.protobuf.Descriptors;
import com.google.protobuf.TextFormat;
import org.apache.hadoop.classification.InterfaceAudience.Private;
Expand Down Expand Up @@ -77,7 +78,9 @@ public static ConfigurationProto readUserSpecifiedTezConfiguration(String baseDi
IOException {
File confPBFile = new File(baseDir, TezConstants.TEZ_PB_BINARY_CONF_NAME);
try (FileInputStream fis = new FileInputStream(confPBFile)) {
return ConfigurationProto.parseFrom(fis);
CodedInputStream in = CodedInputStream.newInstance(fis);
in.setSizeLimit(Integer.MAX_VALUE);
return ConfigurationProto.parseFrom(in);
}
}

Expand Down

0 comments on commit 0712849

Please sign in to comment.