/* This is -*- C -*- */ /* vim: set sw=2: */ /* $Id: check-missing.c,v 1.1 2001/08/21 02:32:15 trow Exp $ */ /* * check-missing.c * * Copyright (C) 2001 The Free Software Foundation, Inc. * * Developed by Jon Trowbridge */ /* * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as * published by the Free Software Foundation; either version 2 of the * License, or (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 * USA. */ #include #include "check-missing.h" gboolean check_missing (GuppiSeq *seq, gint count, ...) { va_list args; gint *missing = g_new0 (gint, count); gint i, i0, i1, j; gboolean ok = TRUE; if (guppi_seq_missing_count (seq) != count) { g_print (">> missing count is %d, should be %d\n", guppi_seq_missing_count (seq), count); return FALSE; } va_start (args, count); for (i=0; i> %d spuriously missing\n", i); ok = FALSE; } } else { for (j = 0; j < count; ++j) if (missing[j] == i) { g_print (">> %d spuriously present\n", i); ok = FALSE; } } } return ok; }