Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
libSDL
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
PocketInsanity
libSDL
Commits
cd6cd131
Commit
cd6cd131
authored
Oct 29, 2011
by
Ryan C. Gordon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
SDL_memcpyMMX(): Fixed handling of overflow bytes.
Thanks to Mason Wheeler for the fix!
parent
e66bcd9e
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
2 deletions
+6
-2
SDL_blit_copy.c
src/video/SDL_blit_copy.c
+6
-2
No files found.
src/video/SDL_blit_copy.c
View file @
cd6cd131
...
@@ -59,6 +59,7 @@ SDL_memcpySSE(Uint8 * dst, const Uint8 * src, int len)
...
@@ -59,6 +59,7 @@ SDL_memcpySSE(Uint8 * dst, const Uint8 * src, int len)
static
__inline__
void
static
__inline__
void
SDL_memcpyMMX
(
Uint8
*
dst
,
const
Uint8
*
src
,
int
len
)
SDL_memcpyMMX
(
Uint8
*
dst
,
const
Uint8
*
src
,
int
len
)
{
{
const
int
remain
=
(
len
&
63
);
int
i
;
int
i
;
__m64
*
d64
=
(
__m64
*
)
dst
;
__m64
*
d64
=
(
__m64
*
)
dst
;
...
@@ -78,8 +79,11 @@ SDL_memcpyMMX(Uint8 * dst, const Uint8 * src, int len)
...
@@ -78,8 +79,11 @@ SDL_memcpyMMX(Uint8 * dst, const Uint8 * src, int len)
s64
+=
8
;
s64
+=
8
;
}
}
if
(
len
&
63
)
if
(
remain
)
SDL_memcpy
(
dst
,
src
,
len
&
63
);
{
const
int
skip
=
len
-
remain
;
SDL_memcpy
(
dst
+
skip
,
src
+
skip
,
remain
);
}
}
}
#endif
/* __MMX__ */
#endif
/* __MMX__ */
...
...
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