Mobile devices have become an important part of our life. Service disruptions can occur because of limited resources of mobile devices such as computation, storage and battery. In this context, mobile cloud computing enables mobile devices to offload their computation and storage to the cloud and get the final result from cloud servers. There are some parameters like bandwidth, delay, jitter and user movement that have an important impact on offloading. This paper proposes a novel solution to overcome problems caused by user movement in the mobile cloud computing context. To this end, we introduce a mobility model and a fault tolerance mechanism for optimizing the offloading decision. Simulation results showed that our proposal can reduce the execution time of mobile applications.