[or-cvs] Suggestion from weasel: Make tor --version --version dump t...

Nick Mathewson nickm at seul.org
Mon Nov 29 22:25:38 UTC 2004


Update of /home/or/cvsroot/tor/src/or
In directory moria.mit.edu:/tmp/cvs-serv3880/src/or

Modified Files:
	buffers.c circuitbuild.c circuitlist.c circuituse.c command.c 
	config.c connection.c connection_edge.c connection_or.c 
	control.c cpuworker.c directory.c dirserv.c dns.c hibernate.c 
	main.c onion.c or.h relay.c rendclient.c rendcommon.c 
	rendmid.c rendservice.c rephist.c router.c routerlist.c 
	routerparse.c test.c tor_main.c 
Log Message:
Suggestion from weasel: Make tor --version --version dump the cvs Id of every file.

Index: buffers.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/buffers.c,v
retrieving revision 1.119
retrieving revision 1.120
diff -u -d -r1.119 -r1.120
--- buffers.c	28 Nov 2004 11:39:53 -0000	1.119
+++ buffers.c	29 Nov 2004 22:25:29 -0000	1.120
@@ -3,6 +3,7 @@
  * Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char buffers_c_id[] = "$Id$";
 
 /**
  * \file buffers.c

Index: circuitbuild.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/circuitbuild.c,v
retrieving revision 1.64
retrieving revision 1.65
diff -u -d -r1.64 -r1.65
--- circuitbuild.c	28 Nov 2004 11:39:53 -0000	1.64
+++ circuitbuild.c	29 Nov 2004 22:25:29 -0000	1.65
@@ -3,6 +3,7 @@
  * Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char circuitbuild_c_id[] = "$Id$";
 
 /**
  * \file circuitbuild.c

Index: circuitlist.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/circuitlist.c,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -d -r1.21 -r1.22
--- circuitlist.c	28 Nov 2004 11:39:53 -0000	1.21
+++ circuitlist.c	29 Nov 2004 22:25:29 -0000	1.22
@@ -3,6 +3,7 @@
  * Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char circuitlist_c_id[] = "$Id$";
 
 /**
  * \file circuitlist.c

Index: circuituse.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/circuituse.c,v
retrieving revision 1.28
retrieving revision 1.29
diff -u -d -r1.28 -r1.29
--- circuituse.c	29 Nov 2004 08:34:54 -0000	1.28
+++ circuituse.c	29 Nov 2004 22:25:29 -0000	1.29
@@ -3,6 +3,7 @@
  * Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char circuituse_c_id[] = "$Id$";
 
 /**
  * \file circuituse.c

Index: command.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/command.c,v
retrieving revision 1.76
retrieving revision 1.77
diff -u -d -r1.76 -r1.77
--- command.c	28 Nov 2004 09:05:46 -0000	1.76
+++ command.c	29 Nov 2004 22:25:29 -0000	1.77
@@ -3,6 +3,7 @@
  * Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char command_c_id[] = "$Id$";
 
 /**
  * \file command.c

Index: config.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/config.c,v
retrieving revision 1.270
retrieving revision 1.271
diff -u -d -r1.270 -r1.271
--- config.c	28 Nov 2004 09:05:46 -0000	1.270
+++ config.c	29 Nov 2004 22:25:29 -0000	1.271
@@ -3,6 +3,7 @@
  * Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char config_c_id[] = "$Id$";
 
 /**
  * /file config.c
@@ -15,6 +16,7 @@
 #ifdef MS_WINDOWS
 #include <shlobj.h>
 #endif
+#include "../common/aes.h"
 
 /** Enumeration of types which option values can take */
 typedef enum config_type_t {
@@ -193,6 +195,7 @@
 
 static uint64_t config_parse_memunit(const char *s, int *ok);
 static int config_parse_interval(const char *s, int *ok);
+static void print_cvs_version(void);
 
 /*
  * Functions to read and write the global options pointer.
@@ -1578,6 +1581,9 @@
 
   if (argc > 1 && (!strcmp(argv[1],"--version"))) {
     printf("Tor version %s.\n",VERSION);
+    if (argc > 2 && (!strcmp(argv[2],"--version"))) {
+      print_cvs_version();
+    }
     exit(0);
   }
 
@@ -2334,3 +2340,91 @@
   return (int)r;
 }
 
+static void
+print_cvs_version(void)
+{
+  extern const char aes_c_id[];
+  extern const char compat_c_id[];
+  extern const char container_c_id[];
+  extern const char crypto_c_id[];
+  extern const char fakepoll_c_id[];
+  extern const char log_c_id[];
+  extern const char torgzip_c_id[];
+  extern const char tortls_c_id[];
+  extern const char util_c_id[];
+
+  extern const char buffers_c_id[];
+  extern const char circuitbuild_c_id[];
+  extern const char circuitlist_c_id[];
+  extern const char circuituse_c_id[];
+  extern const char command_c_id[];
+  extern const char config_c_id[];
+  extern const char connection_c_id[];
+  extern const char connection_edge_c_id[];
+  extern const char connection_or_c_id[];
+  extern const char control_c_id[];
+  extern const char cpuworker_c_id[];
+  extern const char directory_c_id[];
+  extern const char dirserv_c_id[];
+  extern const char dns_c_id[];
+  extern const char hibernate_c_id[];
+  extern const char main_c_id[];
+  extern const char onion_c_id[];
+  extern const char relay_c_id[];
+  extern const char rendclient_c_id[];
+  extern const char rendcommon_c_id[];
+  extern const char rendmid_c_id[];
+  extern const char rendservice_c_id[];
+  extern const char rephist_c_id[];
+  extern const char router_c_id[];
+  extern const char routerlist_c_id[];
+  extern const char routerparse_c_id[];
+
+  puts(AES_H_ID);
+  puts(COMPAT_H_ID);
+  puts(CONTAINER_H_ID);
+  puts(CRYPTO_H_ID);
+  puts(FAKEPOLL_H_ID);
+  puts(LOG_H_ID);
+  puts(TORGZIP_H_ID);
+  puts(TORINT_H_ID);
+  puts(TORTLS_H_ID);
+  puts(UTIL_H_ID);
+  puts(aes_c_id);
+  puts(compat_c_id);
+  puts(container_c_id);
+  puts(crypto_c_id);
+  puts(fakepoll_c_id);
+  puts(log_c_id);
+  puts(torgzip_c_id);
+  puts(tortls_c_id);
+  puts(util_c_id);
+
+  puts(OR_H_ID);
+  puts(buffers_c_id);
+  puts(circuitbuild_c_id);
+  puts(circuitlist_c_id);
+  puts(circuituse_c_id);
+  puts(command_c_id);
+  puts(config_c_id);
+  puts(connection_c_id);
+  puts(connection_edge_c_id);
+  puts(connection_or_c_id);
+  puts(control_c_id);
+  puts(cpuworker_c_id);
+  puts(directory_c_id);
+  puts(dirserv_c_id);
+  puts(dns_c_id);
+  puts(hibernate_c_id);
+  puts(main_c_id);
+  puts(onion_c_id);
+  puts(relay_c_id);
+  puts(rendclient_c_id);
+  puts(rendcommon_c_id);
+  puts(rendmid_c_id);
+  puts(rendservice_c_id);
+  puts(rephist_c_id);
+  puts(router_c_id);
+  puts(routerlist_c_id);
+  puts(routerparse_c_id);
+}

Index: connection.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/connection.c,v
retrieving revision 1.303
retrieving revision 1.304
diff -u -d -r1.303 -r1.304
--- connection.c	29 Nov 2004 08:34:54 -0000	1.303
+++ connection.c	29 Nov 2004 22:25:29 -0000	1.304
@@ -3,6 +3,7 @@
  * Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char connection_c_id[] = "$Id$";
 
 /**
  * \file connection.c

Index: connection_edge.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/connection_edge.c,v
retrieving revision 1.245
retrieving revision 1.246
diff -u -d -r1.245 -r1.246
--- connection_edge.c	29 Nov 2004 08:34:54 -0000	1.245
+++ connection_edge.c	29 Nov 2004 22:25:30 -0000	1.246
@@ -3,6 +3,7 @@
  * Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char connection_edge_c_id[] = "$Id$";
 
 /**
  * \file connection_edge.c

Index: connection_or.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/connection_or.c,v
retrieving revision 1.148
retrieving revision 1.149
diff -u -d -r1.148 -r1.149
--- connection_or.c	28 Nov 2004 11:39:53 -0000	1.148
+++ connection_or.c	29 Nov 2004 22:25:30 -0000	1.149
@@ -3,6 +3,7 @@
  * Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char connection_or_c_id[] = "$Id$";
 
 /**
  * \file connection_or.c

Index: control.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/control.c,v
retrieving revision 1.31
retrieving revision 1.32
diff -u -d -r1.31 -r1.32
--- control.c	28 Nov 2004 09:05:46 -0000	1.31
+++ control.c	29 Nov 2004 22:25:30 -0000	1.32
@@ -1,6 +1,7 @@
 /* Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char control_c_id[] = "$Id$";
 
 /**
  * /file control.c

Index: cpuworker.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/cpuworker.c,v
retrieving revision 1.59
retrieving revision 1.60
diff -u -d -r1.59 -r1.60
--- cpuworker.c	28 Nov 2004 11:39:53 -0000	1.59
+++ cpuworker.c	29 Nov 2004 22:25:30 -0000	1.60
@@ -2,6 +2,7 @@
  * Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char cpuworker_c_id[] = "$Id$";
 
 /**
  * \file cpuworker.c

Index: directory.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/directory.c,v
retrieving revision 1.176
retrieving revision 1.177
diff -u -d -r1.176 -r1.177
--- directory.c	29 Nov 2004 21:01:34 -0000	1.176
+++ directory.c	29 Nov 2004 22:25:30 -0000	1.177
@@ -1,9 +1,8 @@
 /* Copyright 2001-2004 Roger Dingledine.
  * Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
-
-/* See LICENSE for licensing information */
 /* $Id$ */
+const char directory_c_id[] = "$Id$";
 
 #include "or.h"
 

Index: dirserv.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/dirserv.c,v
retrieving revision 1.126
retrieving revision 1.127
diff -u -d -r1.126 -r1.127
--- dirserv.c	28 Nov 2004 11:39:53 -0000	1.126
+++ dirserv.c	29 Nov 2004 22:25:30 -0000	1.127
@@ -2,6 +2,7 @@
  * Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char dirserv_c_id[] = "$Id$";
 
 #include "or.h"
 

Index: dns.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/dns.c,v
retrieving revision 1.123
retrieving revision 1.124
diff -u -d -r1.123 -r1.124
--- dns.c	28 Nov 2004 11:39:53 -0000	1.123
+++ dns.c	29 Nov 2004 22:25:30 -0000	1.124
@@ -2,6 +2,7 @@
  * Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char dns_c_id[] = "$Id$";
 
 /**
  * \file dns.c

Index: hibernate.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/hibernate.c,v
retrieving revision 1.33
retrieving revision 1.34
diff -u -d -r1.33 -r1.34
--- hibernate.c	28 Nov 2004 09:05:46 -0000	1.33
+++ hibernate.c	29 Nov 2004 22:25:30 -0000	1.34
@@ -1,6 +1,7 @@
 /* Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char hibernate_c_id[] = "$Id$";
 
 /**
  * \file hibernate.c

Index: main.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/main.c,v
retrieving revision 1.396
retrieving revision 1.397
diff -u -d -r1.396 -r1.397
--- main.c	28 Nov 2004 11:39:53 -0000	1.396
+++ main.c	29 Nov 2004 22:25:30 -0000	1.397
@@ -3,6 +3,7 @@
  * Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char main_c_id[] = "$Id$";
 
 /**
  * \file main.c

Index: onion.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/onion.c,v
retrieving revision 1.171
retrieving revision 1.172
diff -u -d -r1.171 -r1.172
--- onion.c	28 Nov 2004 09:05:46 -0000	1.171
+++ onion.c	29 Nov 2004 22:25:30 -0000	1.172
@@ -3,6 +3,7 @@
  * Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char onion_c_id[] = "$Id$";
 
 /**
  * \file onion.c

Index: or.h
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/or.h,v
retrieving revision 1.497
retrieving revision 1.498
diff -u -d -r1.497 -r1.498
--- or.h	29 Nov 2004 21:01:34 -0000	1.497
+++ or.h	29 Nov 2004 22:25:30 -0000	1.498
@@ -12,6 +12,7 @@
 
 #ifndef __OR_H
 #define __OR_H
+#define OR_H_ID "$Id$"
 
 #include "orconfig.h"
 #ifdef MS_WINDOWS

Index: relay.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/relay.c,v
retrieving revision 1.28
retrieving revision 1.29
diff -u -d -r1.28 -r1.29
--- relay.c	28 Nov 2004 11:39:53 -0000	1.28
+++ relay.c	29 Nov 2004 22:25:30 -0000	1.29
@@ -3,6 +3,7 @@
  * Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char relay_c_id[] = "$Id$";
 
 /**
  * \file relay.c

Index: rendclient.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/rendclient.c,v
retrieving revision 1.68
retrieving revision 1.69
diff -u -d -r1.68 -r1.69
--- rendclient.c	29 Nov 2004 08:34:54 -0000	1.68
+++ rendclient.c	29 Nov 2004 22:25:30 -0000	1.69
@@ -1,6 +1,7 @@
 /* Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char rendclient_c_id[] = "$Id$";
 
 /**
  * \file rendclient.c

Index: rendcommon.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/rendcommon.c,v
retrieving revision 1.42
retrieving revision 1.43
diff -u -d -r1.42 -r1.43
--- rendcommon.c	28 Nov 2004 09:05:46 -0000	1.42
+++ rendcommon.c	29 Nov 2004 22:25:30 -0000	1.43
@@ -1,6 +1,7 @@
 /* Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char rendcommon_c_id[] = "$Id$";
 
 /**
  * \file rendcommon.c

Index: rendmid.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/rendmid.c,v
retrieving revision 1.32
retrieving revision 1.33
diff -u -d -r1.32 -r1.33
--- rendmid.c	26 Nov 2004 04:00:54 -0000	1.32
+++ rendmid.c	29 Nov 2004 22:25:30 -0000	1.33
@@ -1,6 +1,7 @@
 /* Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char rendmid_c_id[] = "$Id$";
 
 /**
  * \file rendmid.c

Index: rendservice.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/rendservice.c,v
retrieving revision 1.108
retrieving revision 1.109
diff -u -d -r1.108 -r1.109
--- rendservice.c	28 Nov 2004 09:05:46 -0000	1.108
+++ rendservice.c	29 Nov 2004 22:25:30 -0000	1.109
@@ -1,6 +1,7 @@
 /* Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char rendservice_c_id[] = "$Id$";
 
 /**
  * \file rendservice.c

Index: rephist.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/rephist.c,v
retrieving revision 1.44
retrieving revision 1.45
diff -u -d -r1.44 -r1.45
--- rephist.c	28 Nov 2004 09:05:46 -0000	1.44
+++ rephist.c	29 Nov 2004 22:25:30 -0000	1.45
@@ -1,6 +1,7 @@
 /* Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char rephist_c_id[] = "$Id$";
 
 /**
  * \file rephist.c

Index: router.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/router.c,v
retrieving revision 1.131
retrieving revision 1.132
diff -u -d -r1.131 -r1.132
--- router.c	28 Nov 2004 15:49:12 -0000	1.131
+++ router.c	29 Nov 2004 22:25:30 -0000	1.132
@@ -3,6 +3,7 @@
  * Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char router_c_id[] = "$Id$";
 
 #include "or.h"
 

Index: routerlist.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/routerlist.c,v
retrieving revision 1.193
retrieving revision 1.194
diff -u -d -r1.193 -r1.194
--- routerlist.c	29 Nov 2004 21:01:34 -0000	1.193
+++ routerlist.c	29 Nov 2004 22:25:30 -0000	1.194
@@ -3,6 +3,7 @@
  * Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char routerlist_c_id[] = "$Id$";
 
 #include "or.h"
 

Index: routerparse.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/routerparse.c,v
retrieving revision 1.87
retrieving revision 1.88
diff -u -d -r1.87 -r1.88
--- routerparse.c	28 Nov 2004 11:39:53 -0000	1.87
+++ routerparse.c	29 Nov 2004 22:25:30 -0000	1.88
@@ -3,6 +3,7 @@
  * Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char routerparse_c_id[] = "$Id$";
 
 /**
  * \file routerparse.c

Index: test.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/test.c,v
retrieving revision 1.153
retrieving revision 1.154
diff -u -d -r1.153 -r1.154
--- test.c	29 Nov 2004 08:34:54 -0000	1.153
+++ test.c	29 Nov 2004 22:25:30 -0000	1.154
@@ -2,6 +2,7 @@
  * Copyright 2004 Roger Dingledine, Nick Mathewson. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char test_c_id[] = "$Id$";
 
 #include <stdio.h>
 #ifdef HAVE_FCNTL_H

Index: tor_main.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/tor_main.c,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -d -r1.6 -r1.7
--- tor_main.c	26 Nov 2004 04:00:55 -0000	1.6
+++ tor_main.c	29 Nov 2004 22:25:31 -0000	1.7
@@ -1,6 +1,7 @@
 /* Copyright 2001-2004 Roger Dingledine. */
 /* See LICENSE for licensing information */
 /* $Id$ */
+const char tor_main_c_id[] = "$Id$";
 
 /**
  * \file tor_main.c



More information about the tor-commits mailing list