MCPcopy Index your code
hub / github.com/sqlmapproject/sqlmap / beep

Function beep

extra/beep/beep.py:16–29  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

14BEEP_WAV_FILENAME = os.path.join(os.path.dirname(__file__), "beep.wav")
15
16def beep():
17 try:
18 if sys.platform.startswith("win"):
19 _win_wav_play(BEEP_WAV_FILENAME)
20 elif sys.platform.startswith("darwin"):
21 _mac_wav_play(BEEP_WAV_FILENAME)
22 elif sys.platform.startswith("cygwin"):
23 _cygwin_beep(BEEP_WAV_FILENAME)
24 elif any(sys.platform.startswith(_) for _ in ("linux", "freebsd")):
25 _linux_wav_play(BEEP_WAV_FILENAME)
26 else:
27 _speaker_beep()
28 except:
29 _speaker_beep()
30
31def _speaker_beep():
32 sys.stdout.write('\a') # doesn't work on modern Linux systems

Callers 4

checkSqlInjectionFunction · 0.90
readInputFunction · 0.90
beep.pyFile · 0.85

Calls 5

_win_wav_playFunction · 0.85
_mac_wav_playFunction · 0.85
_cygwin_beepFunction · 0.85
_linux_wav_playFunction · 0.85
_speaker_beepFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…