You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by gg...@apache.org on 2023/11/12 17:55:30 UTC
(commons-compress) 01/03: Format tweak
This is an automated email from the ASF dual-hosted git repository.
ggregory pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-compress.git
commit 12d3278e027db1adc6f3f6e94c3e5451b7e4a04a
Author: Gary Gregory <ga...@gmail.com>
AuthorDate: Sun Nov 12 12:37:34 2023 -0500
Format tweak
---
.../commons/compress/archivers/cpio/CpioArchiveEntry.java | 10 ++++------
1 file changed, 4 insertions(+), 6 deletions(-)
diff --git a/src/main/java/org/apache/commons/compress/archivers/cpio/CpioArchiveEntry.java b/src/main/java/org/apache/commons/compress/archivers/cpio/CpioArchiveEntry.java
index 4e1988a3b..64cdd63e9 100644
--- a/src/main/java/org/apache/commons/compress/archivers/cpio/CpioArchiveEntry.java
+++ b/src/main/java/org/apache/commons/compress/archivers/cpio/CpioArchiveEntry.java
@@ -286,16 +286,14 @@ public class CpioArchiveEntry implements CpioConstants, ArchiveEntry {
*
* @since 1.1
*/
- public CpioArchiveEntry(final short format, final File inputFile,
- final String entryName) {
+ public CpioArchiveEntry(final short format, final File inputFile, final String entryName) {
this(format, entryName, inputFile.isFile() ? inputFile.length() : 0);
- if (inputFile.isDirectory()){
+ if (inputFile.isDirectory()) {
setMode(C_ISDIR);
- } else if (inputFile.isFile()){
+ } else if (inputFile.isFile()) {
setMode(C_ISREG);
} else {
- throw new IllegalArgumentException("Cannot determine type of file "
- + inputFile.getName());
+ throw new IllegalArgumentException("Cannot determine type of file " + inputFile.getName());
}
// TODO set other fields as needed
setTime(inputFile.lastModified() / 1000);