fix bug for attach sharememory