We study the causal impact of invalidating marginally valid patents during post-grant opposition at the European Patent Office on affected inventors' subsequent patenting. We exploit exogenous variation in invalidation by leveraging the participation of a patent's original examiner in the opposition division as an instrument. We find a disciplinary effect of invalidation: Affected inventors file 20% fewer patent applications in the decade after the decision. This effect is entirely driven by a reduction in low-quality filings, i.e., filings that examiners associate with prior art that threatens the application's novelty or inventive step. We do not observe shifts into national patenting. JEL-Codes: O310, O340.