ccid: Remove incorrect expression leading to errors.
authorJoshua Rogers <git@internot.info>
Fri, 23 Jan 2015 16:03:33 +0000 (03:03 +1100)
committerWerner Koch <wk@gnupg.org>
Sun, 25 Jan 2015 09:43:52 +0000 (10:43 +0100)
* scd/ccid-driver.c (send_escape_cmd): Fix setting of 'rc'.
--

Variable 'rc' in send_escape_cmd was overwritten before it was
returned, leading to incorrect computation.

Signed-off-by: Joshua Rogers <git@internot.info>
[Log entry reformatted - wk]

(cherry picked from commit 3d9f8bf1dc0c7165a5d2a31568ed425d2dc3b91e)

scd/ccid-driver.c

index 7a91e09..fdfe1f5 100644 (file)
@@ -2230,8 +2230,8 @@ send_escape_cmd (ccid_driver_t handle,
             {
               memcpy (result, msg, msglen);
               *resultlen = msglen;
             {
               memcpy (result, msg, msglen);
               *resultlen = msglen;
+              rc = 0;
             }
             }
-          rc = 0;
         }
         break;
       default:
         }
         break;
       default: