13 lines
354 B
Python
13 lines
354 B
Python
import os
|
|
from pathlib import Path
|
|
|
|
|
|
def crash_once(point: str) -> None:
|
|
"""Точка защиты: оператор явно создаёт /tmp/lab5-crash-<point> внутри контейнера"""
|
|
marker = Path("/tmp") / ("lab5-crash-" + point)
|
|
try:
|
|
marker.unlink()
|
|
except FileNotFoundError:
|
|
return
|
|
os._exit(71)
|