]> git.vomp.tv Git - vompclient-marten.git/commitdiff
Fix var types in remote
authorChris Tallon <chris@vomp.tv>
Sun, 1 Apr 2007 17:30:05 +0000 (17:30 +0000)
committerChris Tallon <chris@vomp.tv>
Sun, 1 Apr 2007 17:30:05 +0000 (17:30 +0000)
remote.cc

index bdaa52f97524c2558d293c3a5c427f0fa6433a03..e1abbfc1128386e30adf8e8f61a32eaabecb8c79 100644 (file)
--- a/remote.cc
+++ b/remote.cc
@@ -169,7 +169,7 @@ void Remote::LoadKeysConfig(char *cfg)
   {
     ULONG ul1, ul2;
     ULONG uc;
-    if (sscanf(start,"%XI%XK%X",&ul1,&ul2,&uc) == 3)
+    if (sscanf(start,"%lXI%lXK%lX",&ul1,&ul2,&uc) == 3)
     {
       translist[((ULLONG) ul1) | ((ULLONG)ul2) << 32]=(UCHAR)uc;
     }
@@ -182,11 +182,10 @@ char *Remote::SaveKeysConfig()
   int length=21*translist.size() +1;
   char *output=new char[length];
   char *current=output;
-  int pos=0;
   RemoteTranslationList::const_iterator it;
   for (it = translist.begin(); it != translist.end(); it++)
   {
-    current+=sprintf(current,"H%08XI%08XK%02X",
+    current+=sprintf(current,"H%08lXI%08lXK%02X",
       (ULONG)it->first ,(ULONG) (it->first >> 32), it->second);
   }
   return output;
@@ -357,7 +356,7 @@ char* Remote::HCWDesc(ULLONG hcw)
   else
   {
     dest=new char[20];
-    sprintf(dest,"C:%X",(ULONG)hcw);
+    sprintf(dest,"C:%lX",(ULONG)hcw);
   }
   return dest;
 }