Обсуждение: $PostgreSQL$ header -- Post 7.4 Release

Поиск
Список
Период
Сортировка

$PostgreSQL$ header -- Post 7.4 Release

От
Rod Taylor
Дата:
New options file for CVSROOT.

Depending on the version of CVS (FreeBSD's CVS to be more specific) is
on the server you may need to manually place this file into the CVSROOT
directory beside the committed options,v file. The reason for this is
that someone missed adding the command to have this file copied on
commit.

Steps:
      * cvs co CVSROOT
      * cp options CVSROOT
      * cvs add options
      * cvs commit options
      * (and possibly) cp options /repo/CVSROOT

The functionality may be tested by adding a $PostgreSQL$ header to one
file. $Id$ and $Header$ have not been disabled. That should wait until
everyone is comfortable with the change.


The below command may be used to convert most $Id$ and $Header$ tags to
$PostgreSQL$ on a checked out copy. Commit as usual.

find . \( -name *.[ch] -or -name Makefile \) \
-type f \
\! -path '*CVS*' \
-exec sed -e 's/$(?:Id|Header)[^$]*$/$PostgreSQL$/' -i.bak {} \;


In src/backend/utils/adt/inet_net_ntop.c and
src/backend/utils/adt/inet_net_pton.c it would appear that the $Id$ tag
is assigned to a variable (rcsid). It doesn't break anything on my
system to change it to $PostgreSQL$.


Вложения

Re: $PostgreSQL$ header -- Post 7.4 Release

От
Neil Conway
Дата:
Rod Taylor <pg@rbt.ca> writes:
> In src/backend/utils/adt/inet_net_ntop.c and
> src/backend/utils/adt/inet_net_pton.c it would appear that the $Id$ tag
> is assigned to a variable (rcsid).

... which is never referenced AFAICT, even if the necessary
preprocessor definitions are set so that it is seen by the compiler in
the first place. Is there a reason not to remove this code from both
files?

-Neil


Re: $PostgreSQL$ header -- Post 7.4 Release

От
Bruce Momjian
Дата:
Neil Conway wrote:
> Rod Taylor <pg@rbt.ca> writes:
> > In src/backend/utils/adt/inet_net_ntop.c and
> > src/backend/utils/adt/inet_net_pton.c it would appear that the $Id$ tag
> > is assigned to a variable (rcsid).
>
> ... which is never referenced AFAICT, even if the necessary
> preprocessor definitions are set so that it is seen by the compiler in
> the first place. Is there a reason not to remove this code from both
> files?

OK, removed with attached patch.  (CVS will update the file name.)

It is a BSD source code style that isn't used by our code.

--
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman@candle.pha.pa.us               |  (610) 359-1001
  +  If your life is a hard drive,     |  13 Roberts Road
  +  Christ can be your backup.        |  Newtown Square, Pennsylvania 19073
Index: src/backend/utils/adt/inet_net_ntop.c
===================================================================
RCS file: /cvsroot/pgsql-server/src/backend/utils/adt/inet_net_ntop.c,v
retrieving revision 1.16
diff -c -c -r1.16 inet_net_ntop.c
*** src/backend/utils/adt/inet_net_ntop.c    4 Aug 2003 00:43:25 -0000    1.16
--- src/backend/utils/adt/inet_net_ntop.c    10 Nov 2003 19:37:34 -0000
***************
*** 13,23 ****
   * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
   * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
   * SOFTWARE.
   */
-
- #if defined(LIBC_SCCS) && !defined(lint)
- static const char rcsid[] = "$Id: inet_net_ntop.c,v 1.16 2003/08/04 00:43:25 momjian Exp $";
- #endif

  #include "postgres.h"

--- 13,21 ----
   * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
   * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
   * SOFTWARE.
+  *
+  *      $Header: /cvsroot/pgsql-server/src/backend/utils/adt/int.c,v 1.57 2003/08/04 02:40:05 momjian Exp $
   */

  #include "postgres.h"

Index: src/backend/utils/adt/inet_net_pton.c
===================================================================
RCS file: /cvsroot/pgsql-server/src/backend/utils/adt/inet_net_pton.c,v
retrieving revision 1.16
diff -c -c -r1.16 inet_net_pton.c
*** src/backend/utils/adt/inet_net_pton.c    4 Aug 2003 00:43:25 -0000    1.16
--- src/backend/utils/adt/inet_net_pton.c    10 Nov 2003 19:37:34 -0000
***************
*** 13,23 ****
   * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
   * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
   * SOFTWARE.
   */
-
- #if defined(LIBC_SCCS) && !defined(lint)
- static const char rcsid[] = "$Id: inet_net_pton.c,v 1.16 2003/08/04 00:43:25 momjian Exp $";
- #endif

  #include "postgres.h"

--- 13,21 ----
   * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
   * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
   * SOFTWARE.
+  *
+  *      $Header: /cvsroot/pgsql-server/src/backend/utils/adt/int.c,v 1.57 2003/08/04 02:40:05 momjian Exp $
   */

  #include "postgres.h"