Skip to content

[fix] fix build failure from package vulnerability#149

Open
thando-ndlovu wants to merge 1 commit into
paulirwin:masterfrom
thando-ndlovu:master
Open

[fix] fix build failure from package vulnerability#149
thando-ndlovu wants to merge 1 commit into
paulirwin:masterfrom
thando-ndlovu:master

Conversation

@thando-ndlovu

Copy link
Copy Markdown

Package 'Tmds.DBus.Protocol' explicitly added as build fails from transient package usage. `Warning As Error: Package 'Tmds.DBus.Protocol' 0.21.2 has a known high severity vulnerability, GHSA-xrw6-gwf8-vvr9

File JavaToCSharpGui\ViewModels\MainWindowViewModel.cs
Line187 has been changed from
int subStartIndex = dir.FullName.Length; to
int subStartIndex = dir.FullName.Length - 1;

  • Fixes exception 'startIndex cannot be larger than length of string. (Parameter 'startIndex')' thrown on line193, string jOutPath = $"{outDirFullName}{jPath[subStartIndex..]}"; when sub directories are not present or .java files are directly under chosen directory
  • Fixes improper directory duplicate creation when sub dirs are present.
    Previous result takes maindir/subdir_one/file_one.java and creates
    maindir/maindir_csharp_outputsubdir_one/file_one.java &
    maindir/maindir_csharp_output/subdir_one/file_one.java

current result takes
maindir/subdir_one/file_one.java and cretes only
maindir/maindir_csharp_output/subdir_one/file_one.java

packageid:Tmds.DBus.Protocol Added
	Warning As Error: Package 'Tmds.DBus.Protocol' 0.21.2 has a known high severity vulnerability, GHSA-xrw6-gwf8-vvr9
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant