Permalink
Browse files

pynfc: proper nfc_exit

  • Loading branch information...
doegox committed Jan 14, 2013
1 parent 9980e1d commit 88ec1f6ea593de3c0ffb23f38a0216ed23ef7a1b
Showing with 3 additions and 1 deletion.
  1. +3 −1 rfidiot/pynfc.py
View
@@ -355,9 +355,11 @@ def deconfigure(self):
self.log.debug("Deconfiguring NFC reader")
#self.powerOff()
self.libnfc.nfc_close(self.device)
+ self.libnfc.nfc_exit(self.context)
if rfidiotglobals.Debug:
self.log.debug("Disconnected NFC reader")
- self.device == None
+ self.device = None
+ self.context = ctypes.POINTER(ctypes.c_int)()
def powerOn(self):
self.libnfc.nfc_device_set_property_bool(self.device, NP_ACTIVATE_FIELD, True)

0 comments on commit 88ec1f6

Please sign in to comment.