Although there is no specific way to fix buffering on the KODI, there are some mandatory items by checking them you can assure that your Internet connection works well and is not the cause of buffering:
At first you have to connect your KODI box to the Internet by using Ethernet cable not the Wireless connection since the wireless get a fraction of the Internet speed not the whole one.
Make sure your Internet speed satisfies the minimum requirement which is at least 10Mbps for streaming VODs and 15Mbps for live streaming. The requirements vary according to the quality of stream and Internet infrastructure of your geographic location.