Skip to content

Conversation

philcali
Copy link
Contributor

Issue #, if available:

Fortify caught this code path again.

Description of changes:

Why is this change necessary:

How was this change tested:

  • StreamManager test locally

Any additional information or context required to review the change:

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

if (!contentPath.toFile().getAbsolutePath().startsWith(stagingPath.toAbsolutePath().toString())) {
final String contentCanonical = contentPath.toFile().getCanonicalPath();
final String stagingCanonical = stagingPath.toFile().getCanonicalPath();
if (!contentCanonical.startsWith(stagingCanonical)) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I remember Urvashi facing an issue in windows tests , so we switched to absolute path. We should verify this works on windows before merging this in

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@urvashijain18 has confirmed that this works for both Mac (host) and Windows (DUT), so I think we're good here.

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.

3 participants