Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
ImportedProjects
SVG
Commits
11d63ae2
Commit
11d63ae2
authored
May 22, 2016
by
Andreas Niedermair
Browse files
fixed SvgImage.GetImage
parent
3bb22f1e
Changes
1
Show whitespace changes
Inline
Side-by-side
Source/Basic Shapes/SvgImage.cs
View file @
11d63ae2
...
...
@@ -234,9 +234,22 @@ namespace Svg
protected
object
GetImage
(
string
uriString
)
{
var
uriString
=
this
.
Href
;
string
safeUriString
;
if
(
uriString
.
Length
>
65519
)
{
safeUriString
=
uriString
.
Substring
(
0
,
65519
);
}
else
{
safeUriString
=
uriString
;
}
try
{
var
uri
=
new
Uri
(
u
riString
.
Substring
(
0
,
65519
)
);
//Uri MaxLength is 65519 (https://msdn.microsoft.com/en-us/library/z6c2z492.aspx)
var
uri
=
new
Uri
(
safeU
riString
);
//Uri MaxLength is 65519 (https://msdn.microsoft.com/en-us/library/z6c2z492.aspx)
// handle data/uri embedded images (http://en.wikipedia.org/wiki/Data_URI_scheme)
if
(
uri
.
IsAbsoluteUri
&&
uri
.
Scheme
==
"data"
)
...
...
Write
Preview
Supports
Markdown
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