Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
chenpangpang
ComfyUI
Commits
e651be55
Commit
e651be55
authored
Mar 25, 2023
by
comfyanonymous
Browse files
Merge branch 'allow-symbolic-link' of
https://github.com/jn-jairo/ComfyUI
parents
bff0c408
4f24e6a1
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
nodes.py
nodes.py
+1
-1
server.py
server.py
+1
-1
No files found.
nodes.py
View file @
e651be55
...
@@ -752,7 +752,7 @@ class SaveImage:
...
@@ -752,7 +752,7 @@ class SaveImage:
full_output_folder
=
os
.
path
.
join
(
self
.
output_dir
,
subfolder
)
full_output_folder
=
os
.
path
.
join
(
self
.
output_dir
,
subfolder
)
if
os
.
path
.
commonpath
((
self
.
output_dir
,
os
.
path
.
real
path
(
full_output_folder
)))
!=
self
.
output_dir
:
if
os
.
path
.
commonpath
((
self
.
output_dir
,
os
.
path
.
abs
path
(
full_output_folder
)))
!=
self
.
output_dir
:
print
(
"Saving image outside the output folder is not allowed."
)
print
(
"Saving image outside the output folder is not allowed."
)
return
{}
return
{}
...
...
server.py
View file @
e651be55
...
@@ -125,7 +125,7 @@ class PromptServer():
...
@@ -125,7 +125,7 @@ class PromptServer():
output_dir
=
os
.
path
.
join
(
os
.
path
.
dirname
(
os
.
path
.
realpath
(
__file__
)),
type
)
output_dir
=
os
.
path
.
join
(
os
.
path
.
dirname
(
os
.
path
.
realpath
(
__file__
)),
type
)
if
"subfolder"
in
request
.
rel_url
.
query
:
if
"subfolder"
in
request
.
rel_url
.
query
:
full_output_dir
=
os
.
path
.
join
(
output_dir
,
request
.
rel_url
.
query
[
"subfolder"
])
full_output_dir
=
os
.
path
.
join
(
output_dir
,
request
.
rel_url
.
query
[
"subfolder"
])
if
os
.
path
.
commonpath
((
os
.
path
.
real
path
(
full_output_dir
),
output_dir
))
!=
output_dir
:
if
os
.
path
.
commonpath
((
os
.
path
.
abs
path
(
full_output_dir
),
output_dir
))
!=
output_dir
:
return
web
.
Response
(
status
=
403
)
return
web
.
Response
(
status
=
403
)
output_dir
=
full_output_dir
output_dir
=
full_output_dir
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment