From dee8790c699fc8a3c027d4ca9210ab3704395b0d Mon Sep 17 00:00:00 2001 From: Jacek Caban Date: Thu, 18 May 2006 22:42:51 +0200 Subject: [PATCH] widl: Don't add importlib if it is already on the list. Remove warning. --- tools/widl/typelib.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/tools/widl/typelib.c b/tools/widl/typelib.c index 77d5155487b..c4b644c3111 100644 --- a/tools/widl/typelib.c +++ b/tools/widl/typelib.c @@ -402,6 +402,13 @@ void add_importlib(const char *name) if(!typelib) return; + for(importlib = typelib->importlibs; importlib; importlib = NEXT_LINK(importlib)) { + if(!strcmp(name, importlib->name)) + return; + } + + chat("add_importlib: %s\n", name); + importlib = xmalloc(sizeof(*importlib)); importlib->name = xstrdup(name); @@ -409,6 +416,4 @@ void add_importlib(const char *name) LINK(importlib, typelib->importlibs); typelib->importlibs = importlib; - - warning("importlib is not yet supported.\n"); }