+
+ /* Oops not seen before, fill in a new complaint. */
+ complaint = XNEW (struct complain);
+ complaint->fmt = fmt;
+ complaint->file = file;
+ complaint->line = line;
+ complaint->counter = 0;
+ complaint->next = NULL;
+
+ /* File it, return it. */
+ complaint->next = complaints->root;
+ complaints->root = complaint;
+ return complaint;
+}
+
+
+/* How many complaints about a particular thing should be printed
+ before we stop whining about it? Default is no whining at all,
+ since so many systems have ill-constructed symbol files. */
+
+static int stop_whining = 0;
+
+/* Print a complaint, and link the complaint block into a chain for
+ later handling. */
+
+static void ATTRIBUTE_PRINTF (4, 0)
+vcomplaint (struct complaints **c, const char *file,
+ int line, const char *fmt,
+ va_list args)
+{
+ struct complaints *complaints = get_complaints (c);
+ struct complain *complaint = find_complaint (complaints, file,
+ line, fmt);
+ enum complaint_series series;
+
+ gdb_assert (complaints != NULL);
+
+ complaint->counter++;