Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
emulab-devel
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
143
Issues
143
List
Boards
Labels
Service Desk
Milestones
Merge Requests
6
Merge Requests
6
Operations
Operations
Incidents
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
emulab
emulab-devel
Commits
45c45e7d
Commit
45c45e7d
authored
Sep 03, 2015
by
Leigh B Stoller
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add ValidURN(). Be sure to unlink tmp file on failed create instance.
parent
979f4ad1
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
2 deletions
+8
-2
www/aptui/instance_defs.php
www/aptui/instance_defs.php
+8
-2
No files found.
www/aptui/instance_defs.php
View file @
45c45e7d
...
...
@@ -238,6 +238,7 @@ class Instance
$retval
=
SUEXEC
(
$uid
,
$pid
,
"webcreate_instance
$options
-u
$uuid
$xmlname
"
,
SUEXEC_ACTION_IGNORE
);
unlink
(
$xmlname
);
if
(
$retval
!=
0
)
{
if
(
$retval
<
0
)
{
...
...
@@ -258,8 +259,6 @@ class Instance
}
return
null
;
}
unlink
(
$xmlname
);
$instance
=
Instance
::
Lookup
(
$uuid
);
if
(
!
$instance
)
{
$errors
[
"error"
]
=
"Transient error(5); please try again later."
;
...
...
@@ -347,6 +346,13 @@ class Instance
}
return
array
();
}
function
ValidURN
(
$urn
)
{
if
(
preg_match
(
"/^[^+]*\+([^+]+)\+([^+]+)\+(.+)$/"
,
$urn
))
{
return
true
;
}
return
false
;
}
function
SetExtensionReason
(
$reason
)
{
...
...
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