Discontiguous network is a network that has two or more subnetworks of a classful network joined together by different classful networks.
In the figure above subnetwork 172.16.10.0/24 and 172.16.20.0/24 are joined together by network 192.168.10.0/24.
What is the issue?
Discontiguous networks become an issue when we are using a classful routing protocol such as RIPv1 or IGRP.
Also, by default they do not work on RIPv2 and EIGRP due to auto summarization feature that is enabled. In order for RIPv2 and EIGRP to support discontiguous networks we must turn off auto summarization.
Since RIPv1 and IGRP are classful routing protocols, when a routing advertisements are sent across a major network boundary they summarize the advertised network to its major classful network address.
To clarify, in the figure below when R1 sends a routing advertisement to R2 about network 172.16.10.0/24, R1 summarizes it to major network 172.16.0.0 because the advertisement is crossing the major network boundary 192.168.10.0/24.
Similarly, when R2 sends a routing advertisement to R1 about network 172.16.20.0/24, R2 summarizes it to major network 172.16.0.0.
The result of this is devices in subnetwork 172.16.10.0/24 and 172.16.20.0/24 cannot communicate with each other.
On the contrary, OSPF by default supports discontiguous networks because it supports VLSM(Classless) and does not auto summarize.