modifications to asock and selectors