Add an option to forbid downloads.
Idea and code-base from Don Elwell <don@manifoldlabs.com>, adapted by me.
/trunk/scripts/functions | 6 6 0 0 ++++++
/trunk/config/global/download.in | 18 18 0 0 ++++++++++++++++++
2 files changed, 24 insertions(+)
1 diff -dur binutils-2.17.old/bfd/opncls.c binutils-2.17/bfd/opncls.c
2 --- binutils-2.17.old/bfd/opncls.c 2006-03-16 13:20:16.000000000 +0100
3 +++ binutils-2.17/bfd/opncls.c 2007-05-01 18:26:11.000000000 +0200
7 const bfd_target *target_vec;
10 + if (stat (filename, &s) == 0)
11 + if (S_ISDIR(s.st_mode)) {
12 + bfd_set_error (bfd_error_file_not_recognized);
16 nbfd = _bfd_new_bfd ();