doxygen: add @file declarations for src/lib

If a file doesn't use the file command (either \file or @file),
Doxygen won't try to process it.

These declarations also turned up a doxygen warning for
crypto_ope.c; I fixed that too.
This commit is contained in:
Nick Mathewson 2019-10-26 11:13:29 -04:00
parent e7993dc046
commit 39d09ea081
20 changed files with 101 additions and 2 deletions

View File

@ -3,6 +3,11 @@
* Copyright (c) 2007-2018, The Tor Project, Inc. */
/* See LICENSE for licensing information */
/**
* @file namemap.c
* @brief Mappings between identifiers and 16-bit ints.
**/
#include "orconfig.h"
#include "lib/container/smartlist.h"
#include "lib/container/namemap.h"

View File

@ -6,6 +6,11 @@
#ifndef NAMEMAP_ST_H
#define NAMEMAP_ST_H
/**
* @file namemap_st.h
* @brief Internal declarations for namemap structure.
**/
#include "lib/cc/compat_compiler.h"
#include "ext/ht.h"

View File

@ -2,7 +2,8 @@
/* See LICENSE for licensing information */
/**
* A rudimentary order-preserving encryption scheme.
* @file crypto_ope.c
* @brief A rudimentary order-preserving encryption scheme.
*
* To compute the encryption of N, this scheme uses an AES-CTR stream to
* generate M-byte values, and adds the first N of them together. (+1 each to
@ -143,7 +144,7 @@ crypto_ope_new(const uint8_t *key)
return ope;
}
/** Free all storage held in <>ope</b>. */
/** Free all storage held in <b>ope</b>. */
void
crypto_ope_free_(crypto_ope_t *ope)
{

View File

@ -1,6 +1,11 @@
/* Copyright (c) 2018-2019, The Tor Project, Inc. */
/* See LICENSE for licensing information */
/**
* @file crypto_ope.h
* @brief header for crypto_ope.c
**/
#ifndef CRYPTO_OPE_H
#define CRYPTO_OPE_H

View File

@ -7,6 +7,11 @@
#ifndef TOR_DISPATCH_CFG_H
#define TOR_DISPATCH_CFG_H
/**
* @file dispatch_cfg.h
* @brief Header for distpach_cfg.c
**/
#include "lib/dispatch/msgtypes.h"
#include "lib/testsupport/testsupport.h"

View File

@ -4,6 +4,11 @@
* Copyright (c) 2007-2018, The Tor Project, Inc. */
/* See LICENSE for licensing information */
/**
* @file dispatch_cfg_st.h
* @brief Declarations for dispatch-configuration types.
**/
#ifndef TOR_DISPATCH_CFG_ST_H
#define TOR_DISPATCH_CFG_ST_H

View File

@ -4,6 +4,11 @@
* Copyright (c) 2007-2018, The Tor Project, Inc. */
/* See LICENSE for licensing information */
/**
* @file dispatch_naming.c
* @brief Name-to-ID maps for our message dispatch system.
**/
#include "orconfig.h"
#include "lib/cc/compat_compiler.h"

View File

@ -4,6 +4,11 @@
* Copyright (c) 2007-2018, The Tor Project, Inc. */
/* See LICENSE for licensing information */
/**
* @file dispatch_naming.h
* @brief Header for dispatch_naming.c
**/
#ifndef TOR_DISPATCH_NAMING_H
#define TOR_DISPATCH_NAMING_H

View File

@ -4,6 +4,11 @@
* Copyright (c) 2007-2019, The Tor Project, Inc. */
/* See LICENSE for licensing information */
/**
* @file country.h
* @brief Country type for geoip.
**/
#ifndef TOR_COUNTRY_H
#define TOR_COUNTRY_H

View File

@ -2,6 +2,11 @@
* Copyright (c) 2004-2006, Roger Dingledine, Nick Mathewson.
* Copyright (c) 2007-2019, The Tor Project, Inc. */
/**
* @file socketpair.c
* @brief Replacement socketpair() for systems that lack it
**/
#include "lib/cc/torint.h"
#include "lib/net/socketpair.h"
#include "lib/net/inaddr_st.h"

View File

@ -6,6 +6,11 @@
#ifndef TOR_SOCKETPAIR_H
#define TOR_SOCKETPAIR_H
/**
* @file socketpair.h
* @brief Header for socketpair.c
**/
#include "orconfig.h"
#include "lib/testsupport/testsupport.h"
#include "lib/net/nettypes.h"

View File

@ -4,6 +4,11 @@
* Copyright (c) 2007-2018, The Tor Project, Inc. */
/* See LICENSE for licensing information */
/**
* @file pubsub_publish.h
* @brief Header for pubsub_publish.c
**/
#ifndef TOR_PUBSUB_PUBLISH_H
#define TOR_PUBSUB_PUBLISH_H

View File

@ -3,6 +3,11 @@
* Copyright (c) 2007-2019, The Tor Project, Inc. */
/* See LICENSE for licensing information */
/**
* @file subsys.h
* @brief Types used to declare a subsystem.
**/
#ifndef TOR_SUBSYS_T
#define TOR_SUBSYS_T

View File

@ -3,6 +3,11 @@
* Copyright (c) 2007-2019, The Tor Project, Inc. */
/* See LICENSE for licensing information */
/**
* @file tortls.c
* @brief Shared functionality for our TLS backends.
**/
#define TORTLS_PRIVATE
#define TOR_X509_PRIVATE
#include "lib/tls/x509.h"

View File

@ -3,6 +3,11 @@
* Copyright (c) 2007-2019, The Tor Project, Inc. */
/* See LICENSE for licensing information */
/**
* @file tortls_internal.h
* @brief Declare internal functions for lib/tls
**/
#ifndef TORTLS_INTERNAL_H
#define TORTLS_INTERNAL_H

View File

@ -6,6 +6,14 @@
#ifndef TOR_TORTLS_ST_H
#define TOR_TORTLS_ST_H
/**
* @file tortls_st.h
* @brief Structure declarations for internal TLS types.
*
* These should generally be treated as opaque outside of the
* lib/tls module.
**/
#include "lib/net/socket.h"
#define TOR_TLS_MAGIC 0x71571571

View File

@ -6,6 +6,11 @@
#include "orconfig.h"
#include "lib/version/git_revision.h"
/**
* @file git_revision.c
* @brief Strings to describe the current Git commit.
**/
/** String describing which Tor Git repository version the source was
* built from. This string is generated by a bit of shell kludging in
* src/core/include.am, and is usually right.

View File

@ -6,6 +6,11 @@
#ifndef TOR_GIT_REVISION_H
#define TOR_GIT_REVISION_H
/**
* @file git_revision.h
* @brief Header for git_revision.c
**/
extern const char tor_git_revision[];
extern const char tor_bug_suffix[];

View File

@ -6,6 +6,11 @@
#ifndef TOR_VERSION_H
#define TOR_VERSION_H
/**
* @file torversion.h
* @brief Header for version.c.
**/
const char *get_version(void);
const char *get_short_version(void);

View File

@ -10,6 +10,11 @@
#include <stdio.h>
#include <string.h>
/**
* @file version.c
* @brief Functions to get the version of Tor.
**/
/** A shorter version of this Tor process's version, for export in our router
* descriptor. (Does not include the git version, if any.) */
static const char the_short_tor_version[] =