Radish alpha
H
rad:z3QDZAW2FAfuLvihrhiyDC9fAD8G9
HardenedBSD Package Manager
Radicle
Git
Whitespace cleanup
Bryan Drewery committed 13 years ago
commit d579e6a1cec3dd7844760f1e217621faebcab5bb
parent 4ba605c
18 files changed +33 -33
modified libpkg/backup.c
@@ -124,7 +124,7 @@ pkgdb_load(struct pkgdb *db, char *dest)
			archive_read_data(a, buf, size);
			pkg_set(pkg, PKG_MTREE, buf);
			free(buf);
-
		} else 
+
		} else
			continue;
	}
	if (pkg != NULL)
modified libpkg/packing.c
@@ -229,7 +229,7 @@ packing_append_tree(struct packing *pack, const char *treepath,
	size_t treelen;
	struct sbuf *sb;
	char *paths[2] = { __DECONST(char *, treepath), NULL };
-
 
+

	treelen = strlen(treepath);
	fts = fts_open(paths, FTS_PHYSICAL | FTS_XDEV, NULL);
	if (fts == NULL)
@@ -265,7 +265,7 @@ packing_append_tree(struct packing *pack, const char *treepath,
			 break;
		default:
			 break;
-
		}   
+
		}
	}
	sbuf_free(sb);
cleanup:
modified libpkg/pkg.c
@@ -737,7 +737,7 @@ pkg_addscript_file(struct pkg *pkg, const char *path)
	filename[0] = '\0';
	filename++;

-
	if (strcmp(filename, "pkg-pre-install") == 0 || 
+
	if (strcmp(filename, "pkg-pre-install") == 0 ||
			strcmp(filename, "+PRE_INSTALL") == 0) {
		type = PKG_SCRIPT_PRE_INSTALL;
	} else if (strcmp(filename, "pkg-post-install") == 0 ||
modified libpkg/pkg.h
@@ -308,7 +308,7 @@ typedef enum {
	 * local file newer than remote
	 */
	EPKG_UPTODATE,
-
	/** 
+
	/**
	 * unkown keyword
	 */
	EPKG_UNKNOWN,
@@ -657,7 +657,7 @@ const char *pkg_shlib_name(struct pkg_shlib const * const);
 * @return EPKG_OK if the package is installed,
 * and != EPKG_OK if the package is not installed or an error occurred
 */
-
int pkg_is_installed(struct pkgdb *db, const char *origin); 
+
int pkg_is_installed(struct pkgdb *db, const char *origin);

/**
 * Create a repository database.
@@ -687,7 +687,7 @@ void pkgdb_close(struct pkgdb *db);
 */
int pkgdb_remote_init(struct pkgdb *db, const char *reponame);

-
/** 
+
/**
 * Dump the content of the database in yaml format
 * only to use when mtree will be deprecated
 */
@@ -703,7 +703,7 @@ int pkgdb_load(struct pkgdb *db, char *dest);
int pkgdb_register_ports(struct pkgdb *db, struct pkg *pkg);

/**
-
 * Unregister a package from the database.
+
 * Unregister a package from the database
 * @return An error code.
 */
int pkgdb_unregister_pkg(struct pkgdb *pkg, const char *origin);
@@ -720,7 +720,7 @@ struct pkgdb_it * pkgdb_search(struct pkgdb *db, const char *pattern,
		match_t type, unsigned int field, const char *reponame);

/**
-
 * 
+
 *
 */
struct pkgdb_it *pkgdb_query_installs(struct pkgdb *db, match_t type, int nbpkgs, char **pkgs, const char *reponame, bool force, bool recursive);
struct pkgdb_it *pkgdb_query_upgrades(struct pkgdb *db, const char *reponame, bool all);
modified libpkg/pkg_config.c
@@ -212,7 +212,7 @@ parse_configuration(yaml_document_t *doc, yaml_node_t *node)
		yaml_node_t *val = yaml_document_get_node(doc, pair->value);

		if (key->data.scalar.length <= 0) {
-
			/* 
+
			/*
			 * ignoring silently empty keys can be empty lines or user mistakes
			 */
			++pair;
modified libpkg/pkg_elf.c
@@ -163,7 +163,7 @@ analyse_elf(struct pkgdb *db, struct pkg *pkg, const char *fpath)
	if ((e = elf_begin(fd, ELF_C_READ, NULL)) == NULL) {
		ret = EPKG_FATAL;
		pkg_emit_error("elf_begin() for %s failed: %s", fpath,
-
		    elf_errmsg(-1)); 
+
		    elf_errmsg(-1));
		goto cleanup;
	}

@@ -236,7 +236,7 @@ analyse_elf(struct pkgdb *db, struct pkg *pkg, const char *fpath)
		if ((dyn = gelf_getdyn(data, dynidx, &dyn_mem)) == NULL) {
			ret = EPKG_FATAL;
			pkg_emit_error("getdyn() failed for %s: %s", fpath,
-
			    elf_errmsg(-1)); 
+
			    elf_errmsg(-1));
			goto cleanup;
		}

@@ -357,7 +357,7 @@ pkg_get_myarch(char *dest, size_t sz)

	if ((elf = elf_begin(fd, ELF_C_READ, NULL)) == NULL) {
		ret = EPKG_FATAL;
-
		pkg_emit_error("elf_begin() failed: %s.", elf_errmsg(-1)); 
+
		pkg_emit_error("elf_begin() failed: %s.", elf_errmsg(-1));
		goto cleanup;
	}

modified libpkg/pkg_manifest.c
@@ -152,7 +152,7 @@ urldecode(const char *src, struct sbuf **dest)
			errno = 0;
			c = strtol(hex, NULL, 16);
			if (errno != 0) {
-
				/* 
+
				/*
				 * if it fails consider this is not a urlencoded
				 * information
				 */
@@ -285,7 +285,7 @@ parse_sequence(struct pkg * pkg, yaml_node_t *node, yaml_document_t *doc,
		case PKG_SHLIBS:
			if (!is_valid_yaml_scalar(val))
				pkg_emit_error("Skipping malformed shared library");
-
			else 
+
			else
				pkg_addshlib(pkg, val->data.scalar.value);
		}
		++item;
@@ -823,7 +823,7 @@ pkg_emit_manifest(struct pkg *pkg, char **dest)
	while (pkg_shlibs(pkg, &shlib) == EPKG_OK)
		manifest_append_seqval(&doc, mapping, &seq, "shlibs",
		    pkg_shlib_name(shlib));
-
 
+

	map = -1;
	while (pkg_options(pkg, &option) == EPKG_OK) {
		if (map == -1)
modified libpkg/pkg_ports.c
@@ -613,7 +613,7 @@ parse_and_apply_keyword_file(yaml_document_t *doc, yaml_node_t *node,
		}

		if (!strcasecmp(key->data.scalar.value, "post-deinstall")) {
-
			if (val->data.scalar.length != 0) { 
+
			if (val->data.scalar.length != 0) {
				format_exec_cmd(&cmd, val->data.scalar.value,
				    p->prefix, p->last_file, line);
				sbuf_cat(p->post_deinstall_buf, cmd);
modified libpkg/pkg_repo.c
@@ -120,7 +120,7 @@ static sql_prstmt sql_prepared_statements[PRSTMT_LAST] = {
		"T",
	},
	[SHLIB2] = {
-
		NULL, 
+
		NULL,
		"INSERT OR ROLLBACK INTO pkg_shlibs(package_id, shlib_id) "
		"VALUES (?1, (SELECT id FROM shlibs WHERE name = ?2))",
		"IT",
@@ -182,7 +182,7 @@ pkg_repo_fetch(struct pkg *pkg)
	if ((retcode = mkdirs(path)) != EPKG_OK)
		goto cleanup;

-
	/* 
+
	/*
	 * In multi-repos the remote URL is stored in pkg[PKG_REPOURL]
	 * For a single attached database the repository URL should be
	 * defined by PACKAGESITE.
@@ -706,7 +706,7 @@ pkg_create_repo(char *path, bool force,

		dep = NULL;
		while (pkg_deps(pkg, &dep) == EPKG_OK) {
-
			if (run_prepared_statement(DEPS, 
+
			if (run_prepared_statement(DEPS,
			    pkg_dep_origin(dep),
			    pkg_dep_name(dep),
			    pkg_dep_version(dep),
@@ -846,7 +846,7 @@ pkg_check_repo_version(struct pkgdb *db, const char *database)
	    != EPKG_OK)
		return (ret);	/* sqlite error */

-
	/* 
+
	/*
	 * If the local pkgng uses a repo schema behind that used to
	 * create the repo, we may still be able use it for reading
	 * (ie pkg install), but pkg repo can't do an incremental
modified libpkg/pkg_version.c
@@ -128,7 +128,7 @@ typedef struct {
 *   sort first (10 < 10a < 10b)
 * - missing version numbers (in components starting with a letter) sort as -1
 *   (a < 0, 10.a < 10)
-
 * - a separator is inserted before the special strings "pl", "alpha", "beta", 
+
 * - a separator is inserted before the special strings "pl", "alpha", "beta",
 *   "pre" and "rc".
 * - "pl" sorts before every other letter, "alpha", "beta", "pre" and "rc"
 *   sort as a, b, p and r. (10alpha = 10.a < 10, but 10 < 10a; pl11 < alpha3
modified pkg/audit.c
@@ -243,7 +243,7 @@ match_version(const char *pkgversion, struct version_entry *v)
	/*
	 * Return true so it is easier for the caller to handle case where there is
	 * only one version to match: the missing one will always match.
-
	 */ 
+
	 */
	if (v->version == NULL)
		return true;

modified pkg/autoremove.c
@@ -142,7 +142,7 @@ exec_autoremove(int argc, char **argv)
			goto cleanup;
	}

-
	if (pkgdb_compact(db) != EPKG_OK) { 
+
	if (pkgdb_compact(db) != EPKG_OK) {
		retcode = EPKG_FATAL;
	}

modified pkg/check.c
@@ -352,7 +352,7 @@ exec_check(int argc, char **argv)
		}

		if (geteuid() == 0 && nbpkgs > 0) {
-
			if (yes == false) 
+
			if (yes == false)
				pkg_config_bool(PKG_CONFIG_ASSUME_ALWAYS_YES, &yes);

			printf("\n>>> Missing package dependencies were detected.\n");
modified pkg/main.c
@@ -101,7 +101,7 @@ usage(void)
	fprintf(stderr, "\t%-15s%s\n\n", "-v", "Display pkg(1) version");
	fprintf(stderr, "Commands supported:\n");

-
	for (unsigned int i = 0; i < cmd_len; i++) 
+
	for (unsigned int i = 0; i < cmd_len; i++)
		fprintf(stderr, "\t%-15s%s\n", cmd[i].name, cmd[i].desc);

	fprintf(stderr, "\nFor more information on the different commands"
modified pkg/pkg-create.8
@@ -135,7 +135,7 @@ for the directory tree the package will use.
See
.Xr mtree 5
for the format of the mtree file.
-
If specified, only a single package will be created. 
+
If specified, only a single package will be created.
Neither
.Fa +DISPLAY
nor
@@ -160,13 +160,13 @@ be saved in the current directory.
.It Fl p Ar plist
Specify some package metadata using the legacy plist format from
.Xr pkg_add 1 ,
-
commonly found in 
+
commonly found in
.Fa pkg-plist
files in the ports tree.
Metadata from the
.Ar plist
file, if specified, will take precedence over any equivalents from
-
the 
+
the
.Ar manifestdir .
Only has any effect when used with
.Ar manifestdir .
modified pkg/pkg.conf.sample
@@ -1,5 +1,5 @@
# System-wide configuration file for pkg(1)
-
# For more information on the file format and 
+
# For more information on the file format and
# options please refer to the pkg.conf(5) man page

# Configuration options
modified pkg/progressmeter.c
@@ -138,7 +138,7 @@ refresh_progress_meter(void)
	bytes_left = end_pos - cur_pos;

	delta_pos = cur_pos - last_pos;
-
	if (delta_pos > max_delta_pos) 
+
	if (delta_pos > max_delta_pos)
		max_delta_pos = delta_pos;

	if (bytes_left > 0)
modified pkg/query.c
@@ -45,7 +45,7 @@ static struct query_flags accepted_query_flags[] = {
	{ 'd', "nov",		1, PKG_LOAD_DEPS },
	{ 'r', "nov",		1, PKG_LOAD_RDEPS },
	{ 'C', "",		1, PKG_LOAD_CATEGORIES },
-
	{ 'F', "ps",		1, PKG_LOAD_FILES }, 
+
	{ 'F', "ps",		1, PKG_LOAD_FILES },
	{ 'O', "kv",		1, PKG_LOAD_OPTIONS },
	{ 'D', "",		1, PKG_LOAD_DIRS },
	{ 'L', "",		1, PKG_LOAD_LICENSES },
@@ -53,7 +53,7 @@ static struct query_flags accepted_query_flags[] = {
	{ 'G', "",		1, PKG_LOAD_GROUPS },
	{ 'B', "",		1, PKG_LOAD_SHLIBS },
	{ '?', "drCFODLUGB",	1, PKG_LOAD_BASIC },	/* dbflags handled in analyse_query_string() */
-
	{ 's', "hb",		0, PKG_LOAD_BASIC }, 
+
	{ 's', "hb",		0, PKG_LOAD_BASIC },
	{ 'n', "",		0, PKG_LOAD_BASIC },
	{ 'v', "",		0, PKG_LOAD_BASIC },
	{ 'o', "",		0, PKG_LOAD_BASIC },