jenkinsci / jenkinsci/subversion-plugin

[JENKINS-60946] Wrong result of function getLocalDir() if "local" equals empty string

Open
#1,528 0 comments 0 reactions 0 assignees View on GitHub
component:subversion-plugin imported-jira-issue priority:major resolution:unresolved
Dominant language
Java
Stars
131
Forks
275
Avg merge
12h 4m
Merged PRs (30d)
6

Description

Current implementation of getLocalDir function

if(local==null)

return getLastPathComponent(getURL());
return local;

When local == "" the function returns workspace, but checkout occurs in last path component of the URL relative to the workspace root.

Conditions should be if(local==null || local == "")

---
Originally reported by yai73w, imported from: Wrong result of function getLocalDir() if "local" equals empty string


  • status: Open
  • priority: Major
  • component(s): subversion-plugin
  • resolution: Unresolved
  • votes: 0
  • watchers: 1
  • imported: 20251212-090250

Raw content of original issue

Current implementation of getLocalDir function



if(local==null)

return getLastPathComponent(getURL());
return local;


When local == "" the function returns workspace, but checkout occurs in last path component of the URL relative to the workspace root.

Conditions should be if(local==null || local == "")

environment

```
Jenkins ver. 2.190.1

Subversion Plug-in 2.12.2
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.