1N/A/*-
1N/A * See the file LICENSE for redistribution information.
1N/A *
1N/A * Copyright (c) 1996, 1997
1N/A * Sleepycat Software. All rights reserved.
1N/A */
1N/A/*
1N/A * Copyright (c) 1998 by Sun Microsystems, Inc.
1N/A * All rights reserved.
1N/A */
1N/A
1N/A#include "config.h"
1N/A
1N/A#pragma ident "%Z%%M% %I% %E% SMI"
1N/A
1N/A#ifndef lint
1N/Astatic const char sccsid[] = "@(#)log_compare.c 10.2 (Sleepycat) 6/21/97";
1N/Astatic const char sccsi2[] = "%W% (Sun) %G%";
1N/A#endif /* not lint */
1N/A
1N/A#ifndef NO_SYSTEM_INCLUDES
1N/A#include <sys/types.h>
1N/A#endif
1N/A
1N/A#include "db_int.h"
1N/A
1N/A/*
1N/A * log_compare --
1N/A * Compare two LSN's.
1N/A */
1N/Aint
1N/Alog_compare(lsn0, lsn1)
1N/A const DB_LSN *lsn0, *lsn1;
1N/A{
1N/A if (lsn0->file != lsn1->file)
1N/A return (lsn0->file < lsn1->file ? -1 : 1);
1N/A
1N/A if (lsn0->offset != lsn1->offset)
1N/A return (lsn0->offset < lsn1->offset ? -1 : 1);
1N/A
1N/A return (0);
1N/A}