diff options
author | Adam Tkac <atkac@redhat.com> | 2010-04-23 13:59:52 +0000 |
---|---|---|
committer | Adam Tkac <atkac@redhat.com> | 2010-04-23 13:59:52 +0000 |
commit | 94d88c1799d6446c132a2ac7198601487d792099 (patch) | |
tree | a875eb50a160f77ffcbc2b27f3dd2b743368a2c5 /common/rfb/Security.cxx | |
parent | 5a0caed91c3879413b23d6906341856d1cc31dc1 (diff) | |
download | tigervnc-94d88c1799d6446c132a2ac7198601487d792099.tar.gz tigervnc-94d88c1799d6446c132a2ac7198601487d792099.zip |
[Development] Define security types as rdr::U8 values.
git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@4034 3789f03b-4d11-0410-bbf8-ca57d06f2519
Diffstat (limited to 'common/rfb/Security.cxx')
-rw-r--r-- | common/rfb/Security.cxx | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/common/rfb/Security.cxx b/common/rfb/Security.cxx index 830d8444..67acf5c9 100644 --- a/common/rfb/Security.cxx +++ b/common/rfb/Security.cxx @@ -22,7 +22,7 @@ #include <rfb/secTypes.h> #include <rfb/util.h> -int rfb::secTypeNum(const char* name) +rdr::U8 rfb::secTypeNum(const char* name) { if (strcasecmp(name, "None") == 0) return secTypeNone; if (strcasecmp(name, "VncAuth") == 0) return secTypeVncAuth; @@ -34,7 +34,7 @@ int rfb::secTypeNum(const char* name) return secTypeInvalid; } -const char* rfb::secTypeName(int num) +const char* rfb::secTypeName(rdr::U8 num) { switch (num) { case secTypeNone: return "None"; @@ -48,7 +48,7 @@ const char* rfb::secTypeName(int num) } } -bool rfb::secTypeEncrypts(int num) +bool rfb::secTypeEncrypts(rdr::U8 num) { switch (num) { case secTypeRA2: @@ -59,13 +59,13 @@ bool rfb::secTypeEncrypts(int num) } } -std::list<int> rfb::parseSecTypes(const char* types_) +std::list<rdr::U8> rfb::parseSecTypes(const char* types_) { - std::list<int> result; + std::list<rdr::U8> result; CharArray types(strDup(types_)), type; while (types.buf) { strSplit(types.buf, ',', &type.buf, &types.buf); - int typeNum = secTypeNum(type.buf); + rdr::U8 typeNum = secTypeNum(type.buf); if (typeNum != secTypeInvalid) result.push_back(typeNum); } |