"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "global/global.c" between
global-6.6.4.tar.gz and global-6.6.5.tar.gz

About: GNU GLOBAL is a source code tag system that works the same way across diverse environments. It is similar to ctags or etags, but it is independent of any editor.

global.c  (global-6.6.4):global.c  (global-6.6.5)
/* /*
* Copyright (c) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2005, 2006, * Copyright (c) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2005, 2006,
* 2007, 2008, 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017 * 2007, 2008, 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017,
* 2020
* Tama Communications Corporation * Tama Communications Corporation
* *
* This file is part of GNU GLOBAL. * This file is part of GNU GLOBAL.
* *
* This program is free software: you can redistribute it and/or modify * This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by * it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or * the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version. * (at your option) any later version.
* *
* This program is distributed in the hope that it will be useful, * This program is distributed in the hope that it will be useful,
skipping to change at line 180 skipping to change at line 181
} }
#define OPT_RESULT 128 #define OPT_RESULT 128
#define OPT_FROM_HERE 129 #define OPT_FROM_HERE 129
#define OPT_ENCODE_PATH 130 #define OPT_ENCODE_PATH 130
#define OPT_MATCH_PART 131 #define OPT_MATCH_PART 131
#define OPT_SINGLE_UPDATE 132 #define OPT_SINGLE_UPDATE 132
#define OPT_PATH_STYLE 133 #define OPT_PATH_STYLE 133
#define OPT_PATH_CONVERT 134 #define OPT_PATH_CONVERT 134
#define OPT_USE_COLOR 135 #define OPT_USE_COLOR 135
#define OPT_GTAGSCONF 136 #define OPT_PRINT 136
#define OPT_GTAGSLABEL 137
#define OPT_PRINT 138
#define SORT_FILTER 1 #define SORT_FILTER 1
#define PATH_FILTER 2 #define PATH_FILTER 2
#define BOTH_FILTER (SORT_FILTER|PATH_FILTER) #define BOTH_FILTER (SORT_FILTER|PATH_FILTER)
#define MATCH_PART_FIRST 1 #define MATCH_PART_FIRST 1
#define MATCH_PART_LAST 2 #define MATCH_PART_LAST 2
#define MATCH_PART_ALL 3 #define MATCH_PART_ALL 3
static const char *short_options = "acde:EifFgGIlL:MnNoOpPqrsS:tTuvVx"; const char *short_options = "acC:de:EifFgGIlL:MnNoOpPqrsS:tTuvVx";
static struct option const long_options[] = { struct option const long_options[] = {
{"absolute", no_argument, NULL, 'a'}, {"absolute", no_argument, NULL, 'a'},
{"directory", required_argument, NULL, 'C'},
{"completion", no_argument, NULL, 'c'}, {"completion", no_argument, NULL, 'c'},
{"definition", no_argument, NULL, 'd'}, {"definition", no_argument, NULL, 'd'},
{"extended-regexp", no_argument, NULL, 'E'}, {"extended-regexp", no_argument, NULL, 'E'},
{"regexp", required_argument, NULL, 'e'}, {"regexp", required_argument, NULL, 'e'},
{"file", no_argument, NULL, 'f'}, {"file", no_argument, NULL, 'f'},
{"first-match", no_argument, NULL, 'F'}, {"first-match", no_argument, NULL, 'F'},
{"local", no_argument, NULL, 'l'}, {"local", no_argument, NULL, 'l'},
{"file-list", required_argument, NULL, 'L'}, {"file-list", required_argument, NULL, 'L'},
{"match-case", no_argument, NULL, 'M'}, {"match-case", no_argument, NULL, 'M'},
{"nofilter", optional_argument, NULL, 'n'}, {"nofilter", optional_argument, NULL, 'n'},
skipping to change at line 395 skipping to change at line 395
int int
main(int argc, char **argv) main(int argc, char **argv)
{ {
const char *av = NULL; const char *av = NULL;
int db; int db;
int optchar; int optchar;
int option_index = 0; int option_index = 0;
int status = 0; int status = 0;
/* /*
* pick up --gtagsconf, --gtagslabel and --directory (-C).
*/
if (preparse_options(argc, argv) < 0)
usage();
/*
* get path of following directories. * get path of following directories.
* o current directory * o current directory
* o root of source tree * o root of source tree
* o dbpath directory * o dbpath directory
* *
* if GTAGS not found, exit with an error message. * if GTAGS not found, exit with an error message.
*/ */
status = setupdbpath(0); status = setupdbpath(0);
if (status == 0) { if (status == 0) {
cwd = get_cwd(); cwd = get_cwd();
root = get_root(); root = get_root();
dbpath = get_dbpath(); dbpath = get_dbpath();
} }
/* /*
* Setup GTAGSCONF and GTAGSLABEL environment variable
* according to the --gtagsconf and --gtagslabel option.
*/
preparse_options(argc, argv);
/*
* Open configuration file. * Open configuration file.
*/ */
openconf(root); openconf(root);
setenv_from_config(); setenv_from_config();
logging_arguments(argc, argv); logging_arguments(argc, argv);
while ((optchar = getopt_long(argc, argv, short_options, long_options, &o ption_index)) != EOF) { while ((optchar = getopt_long(argc, argv, short_options, long_options, &o ption_index)) != EOF) {
switch (optchar) { switch (optchar) {
case 0: case 0:
break; break;
case 'a': case 'a':
skipping to change at line 571 skipping to change at line 571
if (*p != ':') if (*p != ':')
die_with_code(2, "%s", usage); die_with_code(2, "%s", usage);
*p++ = '\0'; *p++ = '\0';
if (!*p) if (!*p)
die_with_code(2, "%s", usage); die_with_code(2, "%s", usage);
context_file = p; context_file = p;
} }
break; break;
case OPT_GTAGSCONF: case OPT_GTAGSCONF:
case OPT_GTAGSLABEL: case OPT_GTAGSLABEL:
/* These options are already parsed in preparse_options() case 'C':
*/ /* These options are already parsed in preparse_options()
. */
break; break;
case OPT_MATCH_PART: case OPT_MATCH_PART:
if (!strcmp(optarg, "first")) if (!strcmp(optarg, "first"))
match_part = MATCH_PART_FIRST; match_part = MATCH_PART_FIRST;
else if (!strcmp(optarg, "last")) else if (!strcmp(optarg, "last"))
match_part = MATCH_PART_LAST; match_part = MATCH_PART_LAST;
else if (!strcmp(optarg, "all")) else if (!strcmp(optarg, "all"))
match_part = MATCH_PART_ALL; match_part = MATCH_PART_ALL;
else else
die_with_code(2, "unknown part type for the --mat ch-part option."); die_with_code(2, "unknown part type for the --mat ch-part option.");
 End of changes. 7 change blocks. 
13 lines changed or deleted 14 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)