Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
N
noVNC
Project
Project
Details
Activity
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
rasky
noVNC
Commits
eabf4670
Commit
eabf4670
authored
14 years ago
by
Joel Martin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
rfb.js/tight_png: fix indexed receive queue handling.
getCLength was not using the index (RQi) into the receive queue.
parent
4ff85f49
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
7 deletions
+4
-7
rfb.js
include/rfb.js
+4
-7
No files found.
include/rfb.js
View file @
eabf4670
...
...
@@ -1348,9 +1348,7 @@ encHandlers.TIGHT_PNG = function display_tight_png() {
//Util.Debug(">> display_tight_png");
var
ctl
,
cmode
,
clength
,
getCLength
,
color
,
img
;
//Util.Debug(" FBU.rects: " + FBU.rects);
//Util.Debug(" RQlen(): " + RQlen());
//Util.Debug(" RQ.slice(0,20): " + RQ.slice(0,20));
//Util.Debug(" starting RQ.slice(RQi,RQi+20): " + RQ.slice(RQi,RQi+20) + " (" + RQlen() + ")");
FBU
.
bytes
=
1
;
// compression-control byte
if
(
RQlen
()
<
FBU
.
bytes
)
{
...
...
@@ -1398,13 +1396,13 @@ encHandlers.TIGHT_PNG = function display_tight_png() {
// Determine FBU.bytes
switch
(
cmode
)
{
case
"fill"
:
RQ
[
RQi
++
]
;
// shift off ctl
RQ
i
++
;
// shift off ctl
color
=
RQshiftBytes
(
fb_depth
);
canvas
.
fillRect
(
FBU
.
x
,
FBU
.
y
,
FBU
.
width
,
FBU
.
height
,
color
);
break
;
case
"jpeg"
:
case
"png"
:
clength
=
getCLength
(
RQ
,
1
);
clength
=
getCLength
(
RQ
,
RQi
+
1
);
FBU
.
bytes
=
1
+
clength
[
0
]
+
clength
[
1
];
// ctl + clength size + jpeg-data
if
(
RQlen
()
<
FBU
.
bytes
)
{
Util
.
Debug
(
" waiting for TIGHT "
+
cmode
+
" bytes"
);
...
...
@@ -1424,8 +1422,7 @@ encHandlers.TIGHT_PNG = function display_tight_png() {
}
FBU
.
bytes
=
0
;
FBU
.
rects
-=
1
;
//Util.Debug(" ending RQlen(): " + RQlen());
//Util.Debug(" ending RQ.slice(0,20): " + RQ.slice(0,20));
//Util.Debug(" ending RQ.slice(RQi,RQi+20): " + RQ.slice(RQi,RQi+20) + " (" + RQlen() + ")");
//Util.Debug("<< display_tight_png");
return
true
;
};
...
...
This diff is collapsed.
Click to expand it.
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