Ns-3/linux tunnel experiments
[nepi.git] / src / nepi / resources / linux / scripts / linux-passfd.py
index 51cf4e8..ff7014e 100644 (file)
@@ -33,8 +33,10 @@ def get_options():
     vif_type = IFF_TAP
     if options.vif_type and options.vif_type == "IFF_TUN":
         vif_type = IFF_TUN
+    
+    address = base64.b64decode(options.address)
 
-    return (options.address, options.vif_name, vif_type, options.pi)
+    return (address, options.vif_name, vif_type, options.pi)
 
 if __name__ == '__main__':
 
@@ -53,7 +55,6 @@ if __name__ == '__main__':
         os.close(fd)
         raise RuntimeError("Could not retrive file descriptor from %s" % vif_name)
 
-    address = base64.b64decode(address)
 
     sock = socket.socket(socket.AF_UNIX, socket.SOCK_DGRAM)
     sock.connect(address)