Pore-end Effects On Adsorption Hysteresis In Cylindrical and Slit-like Pores