Factory automation applications impose stringent quality of service (QoS) over ultra-reliable and low-latency communication (URLLC) system. However, the existing wireless systems cannot meet the requirement for these mission-critical industrial internet-of-things (IIoT) applications. In this paper, we consider the reconfigurable intelligent surface (RIS)-aided URLLC systems in the smart factory. To facilitate the performance analysis of the practical situation, the presence of phase error at RIS is discussed. We analyze and derive approximate closed-form expression of average decoding error probability (ADEP) and the closed-form expression of performance limits de-lay outage rate (DOR) under our proposed scenario, respectively. Through analytical results and associated numerical examples, we demonstrate the effect of the number of reflecting elements at the RIS, channel blocklength and packet size in achieving high reliability and low latency. Therefore, the deployment of RIS can offer an attractive solution to enhance the reliability over URLLC systems in the smart factory.