# HG changeset patch # User jprovino # Date 1335988026 14400 # Node ID 0ee21d1f799a3a9495f90817494e5411fafc0f82 # Parent 7729f07667000f8fe75c7833e11da57280161f11# Parent 80f2bda36ea86028b19e6a68e1264626923fdaf1 Merge diff -r 7729f0766700 -r 0ee21d1f799a hotspot/src/os/solaris/vm/attachListener_solaris.cpp --- a/hotspot/src/os/solaris/vm/attachListener_solaris.cpp Wed Apr 25 15:06:51 2012 -0700 +++ b/hotspot/src/os/solaris/vm/attachListener_solaris.cpp Wed May 02 15:47:06 2012 -0400 @@ -336,7 +336,9 @@ // Return 0 (success) + file descriptor, or non-0 (error) if (res == 0) { door_desc_t desc; - desc.d_attributes = DOOR_DESCRIPTOR; + // DOOR_RELEASE flag makes sure fd is closed after passing it to + // the client. See door_return(3DOOR) man page. + desc.d_attributes = DOOR_DESCRIPTOR | DOOR_RELEASE; desc.d_data.d_desc.d_descriptor = return_fd; door_return((char*)&res, sizeof(res), &desc, 1); } else {