diff --git a/lib/link.js b/lib/link.js
index <HASH>..<HASH> 100644
--- a/lib/link.js
+++ b/lib/link.js
@@ -23,7 +23,7 @@ function Link(session, handle, linkPolicy) {
   this.remoteHandle = undefined;
 
   this._onAttach = [];
-  if (!!this.policy.reattach) {
+  if (this.policy && this.policy.reattach) {
     this._timeouts = u.generateTimeouts(this.policy.reattach);
   }
 
diff --git a/lib/session.js b/lib/session.js
index <HASH>..<HASH> 100644
--- a/lib/session.js
+++ b/lib/session.js
@@ -242,10 +242,10 @@ Session.prototype._removeLink = function(link) {
   delete this._allocatedHandles[link.policy.options.handle];
   if (link instanceof SenderLink) {
     debug('Removing sender link ' + link.name);
-    delete self._senderLinks[link.name];
+    delete this._senderLinks[link.name];
   } else {
     debug('Removing receiver link ' + link.name);
-    delete self._receiverLinks[link.name];
+    delete this._receiverLinks[link.name];
   }
 };
Better protection against missing policy in link for some unit-tests