Return-Path: X-Original-To: apmail-logging-commits-archive@minotaur.apache.org Delivered-To: apmail-logging-commits-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 91B357F63 for ; Mon, 12 Sep 2011 11:06:21 +0000 (UTC) Received: (qmail 48123 invoked by uid 500); 12 Sep 2011 11:06:19 -0000 Delivered-To: apmail-logging-commits-archive@logging.apache.org Received: (qmail 48092 invoked by uid 500); 12 Sep 2011 11:06:14 -0000 Mailing-List: contact commits-help@logging.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@logging.apache.org Delivered-To: mailing list commits@logging.apache.org Received: (qmail 48073 invoked by uid 99); 12 Sep 2011 11:06:11 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 12 Sep 2011 11:06:11 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 12 Sep 2011 11:06:10 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id 43E73238897A; Mon, 12 Sep 2011 11:05:50 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1169688 - /logging/log4net/trunk/src/Appender/EventLogAppender.cs Date: Mon, 12 Sep 2011 11:05:50 -0000 To: commits@logging.apache.org From: bodewig@apache.org X-Mailer: svnmailer-1.0.8 Message-Id: <20110912110550.43E73238897A@eris.apache.org> Author: bodewig Date: Mon Sep 12 11:05:49 2011 New Revision: 1169688 URL: http://svn.apache.org/viewvc?rev=1169688&view=rev Log: Allow EventId to be specified by a property that is neither a string nor an int in EventLogAppender. LOG4NET-129 Modified: logging/log4net/trunk/src/Appender/EventLogAppender.cs Modified: logging/log4net/trunk/src/Appender/EventLogAppender.cs URL: http://svn.apache.org/viewvc/logging/log4net/trunk/src/Appender/EventLogAppender.cs?rev=1169688&r1=1169687&r2=1169688&view=diff ============================================================================== --- logging/log4net/trunk/src/Appender/EventLogAppender.cs (original) +++ logging/log4net/trunk/src/Appender/EventLogAppender.cs Mon Sep 12 11:05:49 2011 @@ -350,6 +350,10 @@ namespace log4net.Appender else { string eventIDPropertyString = eventIDPropertyObj as string; + if (eventIDPropertyString == null) + { + eventIDPropertyString = eventIDPropertyObj.ToString(); + } if (eventIDPropertyString != null && eventIDPropertyString.Length > 0) { // Read the string property into a number