Permalink
Browse files

explicitly splice off allocated records in free(), free/allocated tes…

…t passes
  • Loading branch information...
1 parent f94e012 commit 68ad1513e7376fc0684428ffbf900119707929cc @substack committed Jul 28, 2012
Showing with 4 additions and 1 deletion.
  1. +3 −0 index.js
  2. +1 −1 package.json
View
@@ -304,6 +304,9 @@ exports.createServer = function (opts) {
roles[role] = rs.filter(function (r) {
var x = r.port === port && r.host === host && r._id === id;
if (x) {
+ var ix = allocated.indexOf(r);
+ if (ix >= 0) allocated.splice(ix, 1);
+
found = {};
Object.keys(r).forEach(function (key) {
found[key] = r[key];
View
@@ -1,7 +1,7 @@
{
"name" : "seaport",
"description" : "service registry and port assignment for clusters",
- "version" : "0.7.6",
+ "version" : "0.7.7",
"repository" : {
"type" : "git",
"url" : "git://github.com/substack/seaport.git"

0 comments on commit 68ad151

Please sign in to comment.