krishnenc / seek-for-android

Automatically exported from code.google.com/p/seek-for-android

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Reader.openSession should get an IOException when no logical channel is available.

GoogleCodeExporter opened this issue · comments

Since refresh tag checking is moved from logical channel to session, there is a 
chance when all logical channels are used and no available logical channel for 
GPAC enforcer to retrieve the refresh tag.   To this case, an IOException 
should be thrown in my opinion.

One of the alternative solutions is to change code on openSession() in the 
Terminal.java as follows:

public ISmartcardServiceSession openSession(SmartcardError error)
....
  try {
    mService.initializeAccessControl(Terminal.this.getName(), null);
  } catch (Exception e ){
    SmartcardService.setError(error,e);
    return null;  // Reader.openSession() will throw an IOException when session is null
  }

Original issue reported on code.google.com by danny.w....@gmail.com on 28 May 2013 at 1:19

I agree, IOException makes more sense in this case. Patch will get integrated 
in future updates.
Patch attached for SCAPI-3.0.0

@Danny: pls verify and close issue when ok

Original comment by Daniel.A...@gi-de.com on 5 Jul 2013 at 2:04

  • Changed state: Fixed

Attachments: