diff options
Diffstat (limited to 'src/tools/ares_getopt.h')
-rw-r--r-- | src/tools/ares_getopt.h | 28 |
1 files changed, 20 insertions, 8 deletions
diff --git a/src/tools/ares_getopt.h b/src/tools/ares_getopt.h index 63acb3b..b80da75 100644 --- a/src/tools/ares_getopt.h +++ b/src/tools/ares_getopt.h @@ -28,16 +28,28 @@ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. + * + * SPDX-License-Identifier: BSD-3-Clause */ int ares_getopt(int nargc, char * const nargv[], const char *ostr); -#undef optarg -#undef optind -#undef opterr -#undef optopt -#undef optreset +#ifdef optarg +# undef optarg +#endif +#ifdef optind +# undef optind +#endif +#ifdef opterr +# undef opterr +#endif +#ifdef optopt +# undef optopt +#endif +#ifdef optreset +# undef optreset +#endif #define optarg ares_optarg #define optind ares_optind @@ -46,8 +58,8 @@ int ares_getopt(int nargc, char * const nargv[], const char *ostr); #define optreset ares_optreset extern char *optarg; -extern int optind; -extern int opterr; -extern int optopt; +extern int optind; +extern int opterr; +extern int optopt; #endif /* ARES_GETOPT_H */ |