We investigate the influence of abrupt changes on boundary-layer instability and transition. Such changes include local porous porous wall, suction/injection and surface roughness, and they may modify the boundary conditions and/or the mean flow thereby affecting instability and transition. However, if the change occurs over a relatively short scale comparable with, or even shorter than, the characteristic wavelength of the instability, the conventional local linear stability theory (LST) becomes invalid. Instead, the effect is exerted through scattering with the abrupt change acting as a local scatter. As an instability mode, e.g. Tollmien-Schlichting (T-S) wave, propagates through the region of abrupt change, it is scattered to acquire a different amplitude. A local scattering approach (LSA) should be formulated instead, in which a transmission coefficient, defined as the ratio of the T-S wave amplitude after the scatter to that before the scatter, is introduced to characterize the effect on instability and transition. A numerical method specifically for solving the local scattering problem is developed. In this method, the equations governing the perturbation are discretized by a five-point finite difference scheme, but most importantly physically correct boundary conditions are imposed at the outlet of the computation domain, unlike most conventional methods where artificial ones are used. This allows the computation to be performed in a fairly small domain. We have applied this method to three cases: local porous wall, semi-infinite porous wall and local suction. We have also performed full direct numerical simulations (DNS) to verify the prediction by LSA for the case of a local porous wall. The LSA is found to be effective and accurate, whereas LST does not work for the conditions of interest. In addition, the calculations show that a porous wall, finite or semi-infinite, enhances the T-S wave while suction significantly stabilizes the T-S wave.