The accepted answer is correct from an electrical engineering point of view, but may be confusing from an aviation standpoint which seems to focus on the P-Lead.
I am an ATPL instructor for this subject, so please allow me to clarify.
The P-Lead (Primary Lead) in aviation is not just a "short-circuit", it is a physical component - a wire - that goes from the Primary winding of the magneto (attached to the engine) to the ignition switch in the cockpit. As such it is fairly long and has to pass through the firewall between the engine compartment and the cockpit. It is therefore vulnerable to being broken (open circuit) or suffering some chaffed insulation, which may cause it to short out to some extaneous metalwork that forms part of the common ground of the aircraft fuselage.
The switch and the P-Lead together bypass the contact breaker points which are designed to open and close to produce the spark.
An AC waveform is produced continuously in the primary circuit while the contact breaker is closed, but this is a fairly low voltage and is not strong enough to produce a high enough voltage in the secondary to produce a spark.
Typcially the secondary circuit will produce a pulse of around 25,000 - 30,000 volts at the exact moment that the contact breaker points open, which causes the magnetic field in the primary circuit to suddenly collapse. This rapid collapse of the stored energy in the soft iron core is what induces the high voltage in the secondary coil, but it only happens when the contact breaker opens.
When the ignition switch is closed, it bypasses the contact breaker so that the circuit can never be broken. In this way, a small AC voltage is continuously induced by the alternating primary current in the secondary, but not enough to produce a spark.
It is designed this way to be fail-safe in flight. Should the P-Lead be broken, the contact breaker points will continue to open and close to produce the spark to keep the engine running. It is not, however, fail safe on the ground as an open circuit on the P-Lead would prevent the mageneto from being shut down by turning the ignition off. (This is why engine shut-down is usually achieved by shutting off the Idle Cut Off (ICO) valve in the carburettor and starving the engine of fuel).
The other failure mode - chaffing of the insulation, is less likely but if a ground short did occur in flight, then the magneto would stop working. To cover this eventuality, two independent ignition systems are used with two spark plugs in each cylinder. One set is driven by the "Left" magneto and the other set driven by the "right" magneto. Normally both magnetos are used to improve combustion efficiency and combustion speed. If one magneto were to fail, the other magneto and its associated spark plugs would continue to keep the engine running, although a drop of around 100 RPM may be noticed due to the impaired combustion efficiency.
The whole system should be checked by the pilot on the ground before and after flight according to the checklist in the aircraft flight manual.