In this paper, the performance of carrier-sense multiple access (CSMA)/collision-avoidance (CA) protocols in the presence of carrier-sensing errors is analyzed. Two types of carrier-sensing errors, i.e., false alarm and miss-detection, are considered, and their impact on the system performance is analyzed using a new CSMA/CA model based on a Markov chain capturing the sensing error at the physical layer. The system throughput and delay as functions of the sensing error probabilities, as well as other CSMA/CA parameters, are obtained, and their sensitivity with respect to a key physical-layer parameter, i.e., the sensing threshold, is analyzed for commonly used energy detectors or matched filters. It is shown that the throughput and delay sensitivity heavily depends on the ratio of the contention window size W to the frame length L, and the throughput is sensitive to the design of the sensing threshold when the ratio W/L is either small or large. The result provides guidelines about how to operate CSMA/CA considering imperfect sensing at the physical layer.