Skip to content

Commit 2e2b74b

Browse files
committed
mitigated build warning about RandomStringUtils.randomAlphanumeric(int) being deprecated - fixes johnthagen#102
1 parent 3359ea2 commit 2e2b74b

File tree

3 files changed

+3
-1
lines changed

3 files changed

+3
-1
lines changed

Diff for: README.md

+1
Original file line numberDiff line numberDiff line change
@@ -144,6 +144,7 @@ Deployment.
144144
## Releases
145145

146146
### 1.6.7 - 20XX-XX-XX
147+
- Mitigated build warning about `RandomStringUtils.randomAlphanumeric(int)` being deprecated.
147148

148149
### 1.6.6 - 2024-01-06
149150

Diff for: resources/META-INF/plugin.xml

+1
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
]]></description>
2424

2525
<change-notes><![CDATA[
26+
- Mitigated build warning about `RandomStringUtils.randomAlphanumeric(int)` being deprecated.
2627
]]>
2728
</change-notes>
2829

Diff for: src/com/github/johnthagen/cppcheck/CppcheckInspection.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ public ProblemDescriptor[] checkFile(@NotNull final PsiFile file,
9292
File tempFile = null;
9393
try {
9494
final CppCheckInspectionImpl inspectionImpl = new CppCheckInspectionImpl(verboseLevel);
95-
tempFile = FileUtil.createTempFile(RandomStringUtils.randomAlphanumeric(8) + "_", vFile.getName(), true);
95+
tempFile = FileUtil.createTempFile(RandomStringUtils.insecure().nextAlphanumeric(8) + "_", vFile.getName(), true);
9696
FileUtil.writeToFile(tempFile, document.getText());
9797
final String cppcheckOutput =
9898
inspectionImpl.executeCommandOnFile(vFile, cppcheckPathFile, prependIncludeDir(cppcheckOptions, vFile),

0 commit comments

Comments
 (0)