This paper is devoted to studying the structure stability and instability of Riemann solutions to a scalar conservation law with a flux function involving discontinuous coefficients under certain small perturbations on the discontinuous coefficient k and the unknown function u. More precisely, the initial data are taken as three piecewise constant states, and the middle region is regarded as the perturbed region with small distance. We can see that the Riemann solutions may be unstable with respect to the small perturbations and the sufficient and necessary condition is also given. The study is based on the so-called double Riemann problem, and wave interactions are considered in detail by employing the method of characteristics.