Skip to content
Snippets Groups Projects
Commit 5fb651f2 authored by Joel Brobecker's avatar Joel Brobecker
Browse files

gdb/copyright.py: Exit if run from the wrong directory

We printed an error, but kept going anyway... ;-)

gdb/ChangeLog:

	* copyright.py (main): Exit if run from the wrong directory.
parent 5dd8bf88
No related branches found
No related tags found
No related merge requests found
2020-01-01 Joel Brobecker <brobecker@adacore.com>
* copyright.py (main): Exit if run from the wrong directory.
2020-01-01 Joel Brobecker <brobecker@adacore.com>
* top.c (print_gdb_version): Change copyright year to 2020.
......
......@@ -34,6 +34,7 @@ import datetime
import os
import os.path
import subprocess
import sys
def get_update_list():
......@@ -143,6 +144,8 @@ def main ():
"""The main subprogram."""
if not os.path.isfile("gnulib/import/extra/update-copyright"):
print "Error: This script must be called from the gdb directory."
sys.exit(1)
root_dir = os.path.dirname(os.getcwd())
os.chdir(root_dir)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment