summaryrefslogtreecommitdiffstats
path: root/common/rfb/CapsList.h
diff options
context:
space:
mode:
authorConstantin Kaplinsky <const@tightvnc.com>2006-09-12 14:10:14 +0000
committerConstantin Kaplinsky <const@tightvnc.com>2006-09-12 14:10:14 +0000
commit4140d9156ba640d4c3f9099b9b0f88c1922c38a5 (patch)
tree5ade7a504952a11f3b4aaf4dc3187ed9669633ea /common/rfb/CapsList.h
parentee6ec19073c9d9ac1bf23515da871af65f6fa7de (diff)
downloadtigervnc-4140d9156ba640d4c3f9099b9b0f88c1922c38a5.tar.gz
tigervnc-4140d9156ba640d4c3f9099b9b0f88c1922c38a5.zip
Finished support for TightVNC protocol extensions in the server code. Now "no authentication" case is handled correctly.
git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@670 3789f03b-4d11-0410-bbf8-ca57d06f2519
Diffstat (limited to 'common/rfb/CapsList.h')
-rw-r--r--common/rfb/CapsList.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/common/rfb/CapsList.h b/common/rfb/CapsList.h
index b8fb8e85..a267e933 100644
--- a/common/rfb/CapsList.h
+++ b/common/rfb/CapsList.h
@@ -48,6 +48,11 @@ namespace rfb {
// Current number of capabilities in the list.
int getSize() const { return numEnabled(); }
+ // Does the list include nothing more than one particular capability?
+ bool includesOnly(rdr::U32 code) {
+ return (numEnabled() == 1 && getByOrder(0) == code);
+ }
+
// Add capability ("standard" vendor).
void addStandard(rdr::U32 code, const char *name);
// Add capability (TightVNC vendor).