PERFORCE change 125207 for review
Garrett Cooper
gcooper at FreeBSD.org
Wed Aug 15 23:23:58 PDT 2007
http://perforce.freebsd.org/chv.cgi?CH=125207
Change 125207 by gcooper at optimus-revised_pkgtools on 2007/08/16 06:22:59
- Fix whitespace on function prototypes.
- Align columns properly.
Affected files ...
.. //depot/projects/soc2007/revised_fbsd_pkgtools/v2/contrib/libpkg/archive_read_open_stream.c#3 edit
.. //depot/projects/soc2007/revised_fbsd_pkgtools/v2/contrib/libpkg/pkg.h#3 edit
.. //depot/projects/soc2007/revised_fbsd_pkgtools/v2/contrib/libpkg/pkg_db_private.h#3 edit
.. //depot/projects/soc2007/revised_fbsd_pkgtools/v2/contrib/libpkg/pkg_repo_files.c#3 edit
.. //depot/projects/soc2007/revised_fbsd_pkgtools/v2/contrib/libpkg/pkg_repo_ftp.c#3 edit
.. //depot/projects/soc2007/revised_fbsd_pkgtools/v2/contrib/libpkg/pkg_repo_private.h#3 edit
.. //depot/projects/soc2007/revised_fbsd_pkgtools/v2/contrib/libpkg/pkg_util.c#3 edit
.. //depot/projects/soc2007/revised_fbsd_pkgtools/v2/contrib/libpkg/pkgfile.c#3 edit
Differences ...
==== //depot/projects/soc2007/revised_fbsd_pkgtools/v2/contrib/libpkg/archive_read_open_stream.c#3 (text+ko) ====
@@ -42,9 +42,9 @@
int archive_read_open_stream(struct archive *, FILE *, size_t);
-static int stream_close(struct archive *, void *);
-static int stream_open(struct archive *, void *);
-static ssize_t stream_read(struct archive *, void *, const void **buff);
+static int stream_close(struct archive *, void *);
+static int stream_open(struct archive *, void *);
+static ssize_t stream_read(struct archive *, void *, const void **buff);
int
archive_read_open_stream(struct archive *a, FILE *fd, size_t block_size)
@@ -101,4 +101,4 @@
free(mine->buffer);
free(mine);
return (ARCHIVE_OK);
-}+}
==== //depot/projects/soc2007/revised_fbsd_pkgtools/v2/contrib/libpkg/pkg.h#3 (text+ko) ====
@@ -49,28 +49,28 @@
*/
struct pkgfile;
-struct pkgfile *pkgfile_new_from_disk(const char *, int);
-struct pkgfile *pkgfile_new_regular(const char *, const char *, uint64_t);
-struct pkgfile *pkgfile_new_symlink(const char *, const char *);
-struct pkgfile *pkgfile_new_hardlink(const char *, const char *);
-struct pkgfile *pkgfile_new_directory(const char *);
-const char *pkgfile_get_name(struct pkgfile *);
-uint64_t pkgfile_get_size(struct pkgfile *);
-const char *pkgfile_get_data(struct pkgfile *);
-FILE *pkgfile_get_fileptr(struct pkgfile *);
-const char *pkgfile_get_type_string(struct pkgfile *);
-int pkgfile_set_cwd(struct pkgfile *, const char *);
-int pkgfile_set_checksum_md5(struct pkgfile *, const char *);
-int pkgfile_compare_checksum_md5(struct pkgfile *);
-int pkgfile_seek(struct pkgfile *, int64_t, int);
-int pkgfile_set_mode(struct pkgfile *, mode_t);
-int pkgfile_append(struct pkgfile *, const char *, uint64_t);
-int pkgfile_append_string(struct pkgfile *, const char *, ...);
-const char *pkgfile_find_line(struct pkgfile *, const char *);
-int pkgfile_remove_line(struct pkgfile *, const char *);
-int pkgfile_write(struct pkgfile *);
-int pkgfile_unlink(struct pkgfile *);
-int pkgfile_free(struct pkgfile *);
+struct pkgfile *pkgfile_new_from_disk(const char *, int);
+struct pkgfile *pkgfile_new_regular(const char *, const char *, uint64_t);
+struct pkgfile *pkgfile_new_symlink(const char *, const char *);
+struct pkgfile *pkgfile_new_hardlink(const char *, const char *);
+struct pkgfile *pkgfile_new_directory(const char *);
+const char *pkgfile_get_name(struct pkgfile *);
+uint64_t pkgfile_get_size(struct pkgfile *);
+const char *pkgfile_get_data(struct pkgfile *);
+FILE *pkgfile_get_fileptr(struct pkgfile *);
+const char *pkgfile_get_type_string(struct pkgfile *);
+int pkgfile_set_cwd(struct pkgfile *, const char *);
+int pkgfile_set_checksum_md5(struct pkgfile *, const char *);
+int pkgfile_compare_checksum_md5(struct pkgfile *);
+int pkgfile_seek(struct pkgfile *, int64_t, int);
+int pkgfile_set_mode(struct pkgfile *, mode_t);
+int pkgfile_append(struct pkgfile *, const char *, uint64_t);
+int pkgfile_append_string(struct pkgfile *, const char *, ...);
+const char *pkgfile_find_line(struct pkgfile *, const char *);
+int pkgfile_remove_line(struct pkgfile *, const char *);
+int pkgfile_write(struct pkgfile *);
+int pkgfile_unlink(struct pkgfile *);
+int pkgfile_free(struct pkgfile *);
/**
* @}
==== //depot/projects/soc2007/revised_fbsd_pkgtools/v2/contrib/libpkg/pkg_db_private.h#3 (text+ko) ====
@@ -28,22 +28,23 @@
#ifndef __LIBPKG_PKG_DB_PRIVATE_H__
#define __LIBPKG_PKG_DB_PRIVATE_H__
-typedef int pkg_db_install_pkg_callback(struct pkg_db *, struct pkg *,
- const char *, int, int, int, pkg_db_action *);
-typedef int pkg_db_is_installed_callback(struct pkg_db *, struct pkg *);
+typedef int pkg_db_install_pkg_callback(struct pkg_db *, struct pkg *,
+ const char *, int, int, int, pkg_db_action *);
+typedef int pkg_db_is_installed_callback(struct pkg_db *, struct pkg *);
typedef struct pkg *pkg_db_get_package_callback(struct pkg_db *,
const char *);
typedef struct pkg **pkg_db_get_installed_match_callback(struct pkg_db *,
pkg_db_match *, unsigned int, const void *);
-typedef int pkg_db_deinstall_pkg_callback(struct pkg_db *, struct pkg *,
- int, int, int, int, pkg_db_action *);
+typedef int pkg_db_deinstall_pkg_callback(struct pkg_db *, struct pkg *,
+ int, int, int, int, pkg_db_action *);
-struct pkg_db *pkg_db_open(const char *, pkg_db_install_pkg_callback *,
- pkg_db_is_installed_callback *,
- pkg_db_get_installed_match_callback *,
- pkg_db_get_package_callback *,
- pkg_db_deinstall_pkg_callback *);
+struct pkg_db *pkg_db_open(const char *, pkg_db_install_pkg_callback *,
+ pkg_db_is_installed_callback *,
+ pkg_db_get_installed_match_callback *,
+ pkg_db_get_package_callback *,
+ pkg_db_deinstall_pkg_callback *);
+
struct pkg_db {
void *data;
==== //depot/projects/soc2007/revised_fbsd_pkgtools/v2/contrib/libpkg/pkg_repo_files.c#3 (text+ko) ====
@@ -36,7 +36,7 @@
#include "pkg_private.h"
#include "pkg_repo_private.h"
-static struct pkg *file_repo_get_pkg(struct pkg_repo *, const char *);
+static struct pkg* file_repo_get_pkg(struct pkg_repo *, const char *);
/**
* @defgroup PackageRepoFiles Local file repository
@@ -100,4 +100,4 @@
/**
* @}
- */+ */
==== //depot/projects/soc2007/revised_fbsd_pkgtools/v2/contrib/libpkg/pkg_repo_ftp.c#3 (text+ko) ====
@@ -74,8 +74,8 @@
{ 503100, 599000, "/packages-5-stable" },
{ 600100, 699000, "/packages-6-stable" },
{ 700000, 799000, "/packages-7-current" },
- { 0, MAX_VERSION, "packages-current" },
- { 0, 0, NULL }
+ { 0, MAX_VERSION, "packages-current" },
+ { 0, 0, NULL }
};
struct ftp_repo {
@@ -91,9 +91,9 @@
static struct pkg *ftp_get_pkg(struct pkg_repo *, const char *);
static int ftp_free(struct pkg_repo *);
/* Internal */
-static FILE *ftp_get_fd(const char *, struct ftp_repo *);
-static struct ftp_repo *ftp_create_repo(const char *, const char *,
- const char *);
+static FILE *ftp_get_fd(const char *, struct ftp_repo *);
+static struct ftp_repo *ftp_create_repo(const char *, const char *,
+ const char *);
/*pkg_static int pkg_in_All(const char *); */
static int pkg_name_has_extension(const char *);
@@ -119,10 +119,9 @@
struct pkg_repo *repo;
repo = pkg_repo_new(ftp_get_pkg, ftp_free);
- if (!repo) {
+ if (!repo)
return NULL;
- }
-
+
repo->data = ftp_create_repo(site, path, cache_dir);
if (!repo->data) {
ftp_free(repo);
@@ -373,4 +372,4 @@
/**
* @}
- */+ */
==== //depot/projects/soc2007/revised_fbsd_pkgtools/v2/contrib/libpkg/pkg_repo_private.h#3 (text+ko) ====
@@ -28,11 +28,11 @@
#ifndef __LIBPKG_PKG_REPO_PRIVATE_H__
#define __LIBPKG_PKG_REPO_PRIVATE_H__
-typedef struct pkg *pkg_repo_get_pkg_callback(struct pkg_repo *, const char *);
-typedef int pkg_repo_free_callback(struct pkg_repo *);
+typedef struct pkg *pkg_repo_get_pkg_callback(struct pkg_repo *, const char *);
+typedef int pkg_repo_free_callback(struct pkg_repo *);
struct pkg_repo *pkg_repo_new(pkg_repo_get_pkg_callback *,
- pkg_repo_free_callback *);
+ pkg_repo_free_callback *);
struct pkg_repo {
void *data;
==== //depot/projects/soc2007/revised_fbsd_pkgtools/v2/contrib/libpkg/pkg_util.c#3 (text+ko) ====
@@ -47,9 +47,9 @@
#include "pkg.h"
#include "pkg_private.h"
-static int pkg_cached_readfn(void *, char *, int);
-static fpos_t pkg_cached_seekfn(void *, fpos_t, int);
-static int pkg_cached_closefn(void *);
+static int pkg_cached_readfn(void *, char *, int);
+static fpos_t pkg_cached_seekfn(void *, fpos_t, int);
+static int pkg_cached_closefn(void *);
/**
* @defgroup PackageUtil Miscellaneous utilities
@@ -340,4 +340,4 @@
/**
* @}
- */+ */
==== //depot/projects/soc2007/revised_fbsd_pkgtools/v2/contrib/libpkg/pkgfile.c#3 (text+ko) ====
@@ -43,10 +43,10 @@
#include "pkg.h"
#include "pkg_private.h"
-static struct pkgfile *pkgfile_new(const char *, pkgfile_type, pkgfile_loc);
-static int pkgfile_open_fd(struct pkgfile *);
-static int pkgfile_get_type(struct pkgfile *);
-static const char *pkgfile_real_name(struct pkgfile *);
+static struct pkgfile *pkgfile_new(const char *, pkgfile_type, pkgfile_loc);
+static int pkgfile_open_fd(struct pkgfile *);
+static int pkgfile_get_type(struct pkgfile *);
+static const char *pkgfile_real_name(struct pkgfile *);
static const char *pkgfile_types[] =
{ "none", "file", "hardlink", "symlink", "directory" };
@@ -996,4 +996,4 @@
/**
* @}
- */+ */
More information about the p4-projects
mailing list