[BACK]Return to patch-slpd_slpd__knownda.c CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / pkgsrc / net / openslp / patches

File: [cvs.NetBSD.org] / pkgsrc / net / openslp / patches / patch-slpd_slpd__knownda.c (download)

Revision 1.1, Thu Feb 11 15:12:06 2016 UTC (8 years, 2 months ago) by he
Branch: MAIN
CVS Tags: pkgsrc-2024Q1-base, pkgsrc-2024Q1, pkgsrc-2023Q4-base, pkgsrc-2023Q4, pkgsrc-2023Q3-base, pkgsrc-2023Q3, pkgsrc-2023Q2-base, pkgsrc-2023Q2, pkgsrc-2023Q1-base, pkgsrc-2023Q1, pkgsrc-2022Q4-base, pkgsrc-2022Q4, pkgsrc-2022Q3-base, pkgsrc-2022Q3, pkgsrc-2022Q2-base, pkgsrc-2022Q2, pkgsrc-2022Q1-base, pkgsrc-2022Q1, pkgsrc-2021Q4-base, pkgsrc-2021Q4, pkgsrc-2021Q3-base, pkgsrc-2021Q3, pkgsrc-2021Q2-base, pkgsrc-2021Q2, pkgsrc-2021Q1-base, pkgsrc-2021Q1, pkgsrc-2020Q4-base, pkgsrc-2020Q4, pkgsrc-2020Q3-base, pkgsrc-2020Q3, pkgsrc-2020Q2-base, pkgsrc-2020Q2, pkgsrc-2020Q1-base, pkgsrc-2020Q1, pkgsrc-2019Q4-base, pkgsrc-2019Q4, pkgsrc-2019Q3-base, pkgsrc-2019Q3, pkgsrc-2019Q2-base, pkgsrc-2019Q2, pkgsrc-2019Q1-base, pkgsrc-2019Q1, pkgsrc-2018Q4-base, pkgsrc-2018Q4, pkgsrc-2018Q3-base, pkgsrc-2018Q3, pkgsrc-2018Q2-base, pkgsrc-2018Q2, pkgsrc-2018Q1-base, pkgsrc-2018Q1, pkgsrc-2017Q4-base, pkgsrc-2017Q4, pkgsrc-2017Q3-base, pkgsrc-2017Q3, pkgsrc-2017Q2-base, pkgsrc-2017Q2, pkgsrc-2017Q1-base, pkgsrc-2017Q1, pkgsrc-2016Q4-base, pkgsrc-2016Q4, pkgsrc-2016Q3-base, pkgsrc-2016Q3, pkgsrc-2016Q2-base, pkgsrc-2016Q2, pkgsrc-2016Q1-base, pkgsrc-2016Q1, HEAD

Add fix for CVE-2015-5177, lifted from
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=795429
Bump PKGREVISION.

$NetBSD: patch-slpd_slpd__knownda.c,v 1.1 2016/02/11 15:12:06 he Exp $

Add fix for CVE-2015-5177, lifted from
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=795429

--- slpd/slpd_knownda.c.orig	2005-02-08 05:34:31.000000000 +0000
+++ slpd/slpd_knownda.c
@@ -823,15 +823,15 @@ int SLPDKnownDAAdd(SLPMessage msg, SLPBu
              */
             SLPDLogDAAdvertisement("Removed",entry);
         }
+        /* If we are here, we need to cleanup the message descriptor and the  */
+        /* message buffer because they were not added to the database and not */
+        /* cleaning them up would result in a memory leak                     */
+        /* We also need to make sure the Database handle is closed.           */
+        SLPMessageFree(msg);
+        SLPBufferFree(buf);
     }
 
     CLEANUP:
-    /* If we are here, we need to cleanup the message descriptor and the  */
-    /* message buffer because they were not added to the database and not */
-    /* cleaning them up would result in a memory leak                     */
-    /* We also need to make sure the Database handle is closed.           */
-    SLPMessageFree(msg);
-    SLPBufferFree(buf);
     if (dh) SLPDatabaseClose(dh);
 
     return result;