From owner-svn-src-vendor@FreeBSD.ORG Mon Feb 17 17:10:46 2014 Return-Path: Delivered-To: svn-src-vendor@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 34942DF2; Mon, 17 Feb 2014 17:10:46 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 18DDE1837; Mon, 17 Feb 2014 17:10:46 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s1HHAksP052914; Mon, 17 Feb 2014 17:10:46 GMT (envelope-from jkim@svn.freebsd.org) Received: (from jkim@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s1HHAfVo052884; Mon, 17 Feb 2014 17:10:41 GMT (envelope-from jkim@svn.freebsd.org) Message-Id: <201402171710.s1HHAfVo052884@svn.freebsd.org> From: Jung-uk Kim Date: Mon, 17 Feb 2014 17:10:41 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org Subject: svn commit: r262091 - in vendor-sys/acpica/dist: . generate/unix source/common source/compiler source/components/debugger source/components/dispatcher source/components/events source/components/exe... X-SVN-Group: vendor-sys MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-vendor@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: SVN commit messages for the vendor work area tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Feb 2014 17:10:46 -0000 Author: jkim Date: Mon Feb 17 17:10:41 2014 New Revision: 262091 URL: http://svnweb.freebsd.org/changeset/base/262091 Log: Import ACPICA 20140214. Modified: vendor-sys/acpica/dist/changes.txt vendor-sys/acpica/dist/generate/unix/Makefile.config vendor-sys/acpica/dist/source/common/adisasm.c vendor-sys/acpica/dist/source/common/dmextern.c vendor-sys/acpica/dist/source/common/dmtbinfo.c vendor-sys/acpica/dist/source/compiler/aslcompiler.h vendor-sys/acpica/dist/source/compiler/aslerror.c vendor-sys/acpica/dist/source/compiler/aslfileio.c vendor-sys/acpica/dist/source/compiler/aslglobal.h vendor-sys/acpica/dist/source/compiler/aslmain.c vendor-sys/acpica/dist/source/compiler/aslmessages.h vendor-sys/acpica/dist/source/compiler/asloptions.c vendor-sys/acpica/dist/source/compiler/aslpredef.c vendor-sys/acpica/dist/source/compiler/aslprepkg.c vendor-sys/acpica/dist/source/compiler/aslstartup.c vendor-sys/acpica/dist/source/compiler/asltransform.c vendor-sys/acpica/dist/source/compiler/dtfield.c vendor-sys/acpica/dist/source/compiler/dttemplate.h vendor-sys/acpica/dist/source/compiler/prmacros.c vendor-sys/acpica/dist/source/components/debugger/dbdisply.c vendor-sys/acpica/dist/source/components/dispatcher/dsinit.c vendor-sys/acpica/dist/source/components/dispatcher/dsmethod.c vendor-sys/acpica/dist/source/components/dispatcher/dswload.c vendor-sys/acpica/dist/source/components/events/evregion.c vendor-sys/acpica/dist/source/components/executer/exdump.c vendor-sys/acpica/dist/source/components/executer/exsystem.c vendor-sys/acpica/dist/source/components/executer/exutils.c vendor-sys/acpica/dist/source/components/namespace/nsinit.c vendor-sys/acpica/dist/source/components/namespace/nsload.c vendor-sys/acpica/dist/source/components/namespace/nsobject.c vendor-sys/acpica/dist/source/components/namespace/nsprepkg.c vendor-sys/acpica/dist/source/components/namespace/nsrepair.c vendor-sys/acpica/dist/source/components/namespace/nsrepair2.c vendor-sys/acpica/dist/source/components/parser/psloop.c vendor-sys/acpica/dist/source/components/parser/psobject.c vendor-sys/acpica/dist/source/components/resources/rscalc.c vendor-sys/acpica/dist/source/components/resources/rscreate.c vendor-sys/acpica/dist/source/components/resources/rsdump.c vendor-sys/acpica/dist/source/components/resources/rsdumpinfo.c vendor-sys/acpica/dist/source/components/resources/rsinfo.c vendor-sys/acpica/dist/source/components/utilities/utdelete.c vendor-sys/acpica/dist/source/components/utilities/utglobal.c vendor-sys/acpica/dist/source/components/utilities/utosi.c vendor-sys/acpica/dist/source/include/acapps.h vendor-sys/acpica/dist/source/include/acbuffer.h vendor-sys/acpica/dist/source/include/acconfig.h vendor-sys/acpica/dist/source/include/acdebug.h vendor-sys/acpica/dist/source/include/acdisasm.h vendor-sys/acpica/dist/source/include/acdispat.h vendor-sys/acpica/dist/source/include/acevents.h vendor-sys/acpica/dist/source/include/acexcep.h vendor-sys/acpica/dist/source/include/acglobal.h vendor-sys/acpica/dist/source/include/achware.h vendor-sys/acpica/dist/source/include/acinterp.h vendor-sys/acpica/dist/source/include/aclocal.h vendor-sys/acpica/dist/source/include/acmacros.h vendor-sys/acpica/dist/source/include/acnamesp.h vendor-sys/acpica/dist/source/include/acobject.h vendor-sys/acpica/dist/source/include/acoutput.h vendor-sys/acpica/dist/source/include/acparser.h vendor-sys/acpica/dist/source/include/acpiosxf.h vendor-sys/acpica/dist/source/include/acpixf.h vendor-sys/acpica/dist/source/include/acpredef.h vendor-sys/acpica/dist/source/include/acresrc.h vendor-sys/acpica/dist/source/include/acrestyp.h vendor-sys/acpica/dist/source/include/acstruct.h vendor-sys/acpica/dist/source/include/actables.h vendor-sys/acpica/dist/source/include/actbl.h vendor-sys/acpica/dist/source/include/actbl1.h vendor-sys/acpica/dist/source/include/actbl2.h vendor-sys/acpica/dist/source/include/actbl3.h vendor-sys/acpica/dist/source/include/actypes.h vendor-sys/acpica/dist/source/include/acutils.h vendor-sys/acpica/dist/source/include/amlcode.h vendor-sys/acpica/dist/source/include/amlresrc.h vendor-sys/acpica/dist/source/os_specific/service_layers/oswindir.c vendor-sys/acpica/dist/source/os_specific/service_layers/oswinxf.c vendor-sys/acpica/dist/source/tools/acpiexec/aecommon.h vendor-sys/acpica/dist/source/tools/acpiexec/aeexec.c vendor-sys/acpica/dist/source/tools/acpiexec/aehandlers.c vendor-sys/acpica/dist/source/tools/acpiexec/aemain.c Modified: vendor-sys/acpica/dist/changes.txt ============================================================================== --- vendor-sys/acpica/dist/changes.txt Mon Feb 17 17:01:41 2014 (r262090) +++ vendor-sys/acpica/dist/changes.txt Mon Feb 17 17:10:41 2014 (r262091) @@ -1,4 +1,69 @@ ---------------------------------------- +14 February 2014. Summary of changes for version 20140214: + +1) ACPICA kernel-resident subsystem: + +Implemented a new mechanism to proactively prevent problems with ill- +behaved reentrant control methods that create named ACPI objects. This +behavior is illegal as per the ACPI specification, but is nonetheless +frequently seen in the field. Previously, this could lead to an +AE_ALREADY_EXISTS exception if the method was actually entered by more +than one thread. This new mechanism detects such methods at table load +time and marks them "serialized" to prevent reentrancy. A new global +option, AcpiGbl_AutoSerializeMethods, has been added to disable this +feature if desired. This mechanism and global option obsoletes and +supersedes the previous AcpiGbl_SerializeAllMethods option. + +Added the "Windows 2013" string to the _OSI support. ACPICA will now +respond TRUE to _OSI queries with this string. It is the stated policy of +ACPICA to add new strings to the _OSI support as soon as possible after +they are defined. See the full ACPICA _OSI policy which has been added to +the utilities/utosi.c file. + +Hardened/updated the _PRT return value auto-repair code: +1) Do not abort the repair on a single subpackage failure, continue to +check all subpackages. +2) Add check for the minimum subpackage length (4). +3) Properly handle extraneous NULL package elements. + +Added support to avoid the possibility of infinite loops when traversing +object linked lists. Never allow an infinite loop, even in the face of +corrupted object lists. + +ACPICA headers: Deployed the use of #pragma pack(push) and #pragma +pack(pop) directives to ensure that the ACPICA headers are independent of +compiler settings or other host headers. + +Example Code and Data Size: These are the sizes for the OS-independent +acpica.lib produced by the Microsoft Visual C++ 9.0 32-bit compiler. The +debug version of the code includes the debug output trace mechanism and +has a much larger code and data size. + + Current Release: + Non-Debug Version: 96.5K Code, 27.2K Data, 123.7K Total + Debug Version: 188.6K Code, 79.0K Data, 267.6K Total + Previous Release: + Non-Debug Version: 96.2K Code, 27.0K Data, 123.2K Total + Debug Version: 187.5K Code, 78.3K Data, 265.8K Total + + +2) iASL Compiler/Disassembler and Tools: + +iASL/Table-compiler: Fixed a problem with support for the SPMI table. The +first reserved field was incorrectly forced to have a value of zero. This +change correctly forces the field to have a value of one. ACPICA BZ 1081. + +Debugger: Added missing support for the "Extra" and "Data" subobjects +when displaying object data. + +Debugger: Added support to display entire object linked lists when +displaying object data. + +iASL: Removed the obsolete -g option to obtain ACPI tables from the +Windows registry. This feature has been superseded by the acpidump +utility. + +---------------------------------------- 14 January 2014. Summary of changes for version 20140114: 1) ACPICA kernel-resident subsystem: Modified: vendor-sys/acpica/dist/generate/unix/Makefile.config ============================================================================== --- vendor-sys/acpica/dist/generate/unix/Makefile.config Mon Feb 17 17:01:41 2014 (r262090) +++ vendor-sys/acpica/dist/generate/unix/Makefile.config Mon Feb 17 17:10:41 2014 (r262091) @@ -161,14 +161,15 @@ CWARNINGFLAGS = \ CWARNINGFLAGS += \ -Waddress\ -Waggregate-return\ - -Wchar-subscripts\ + -Winit-self\ + -Winline\ -Wmissing-declarations\ -Wmissing-field-initializers\ -Wnested-externs\ -Wold-style-definition\ + -Woverride-init\ -Wno-format-nonliteral\ -Wredundant-decls - # # Per-host flags and exclusions # Modified: vendor-sys/acpica/dist/source/common/adisasm.c ============================================================================== --- vendor-sys/acpica/dist/source/common/adisasm.c Mon Feb 17 17:01:41 2014 (r262090) +++ vendor-sys/acpica/dist/source/common/adisasm.c Mon Feb 17 17:10:41 2014 (r262091) @@ -250,7 +250,6 @@ AdInitialize ( * OutToFile - TRUE if output should go to a file * Prefix - Path prefix for output * OutFilename - where the filename is returned - * GetAllTables - TRUE if all tables are desired * * RETURN: Status * @@ -263,8 +262,7 @@ AdAmlDisassemble ( BOOLEAN OutToFile, char *Filename, char *Prefix, - char **OutFilename, - BOOLEAN GetAllTables) + char **OutFilename) { ACPI_STATUS Status; char *DisasmFilename = NULL; @@ -348,7 +346,7 @@ AdAmlDisassemble ( } else { - Status = AdGetLocalTables (Filename, GetAllTables); + Status = AdGetLocalTables (); if (ACPI_FAILURE (Status)) { AcpiOsPrintf ("Could not get ACPI tables, %s\n", @@ -746,8 +744,7 @@ AdDisplayTables ( * * FUNCTION: AdGetLocalTables * - * PARAMETERS: Filename - Not used - * GetAllTables - TRUE if all tables are desired + * PARAMETERS: None * * RETURN: Status * @@ -757,105 +754,36 @@ AdDisplayTables ( ACPI_STATUS AdGetLocalTables ( - char *Filename, - BOOLEAN GetAllTables) + void) { ACPI_STATUS Status; ACPI_TABLE_HEADER TableHeader; ACPI_TABLE_HEADER *NewTable; - UINT32 NumTables; - UINT32 PointerSize; UINT32 TableIndex; - if (GetAllTables) - { - ACPI_MOVE_32_TO_32 (TableHeader.Signature, ACPI_SIG_RSDT); - AcpiOsTableOverride (&TableHeader, &NewTable); - if (!NewTable) - { - fprintf (stderr, "Could not obtain RSDT\n"); - return (AE_NO_ACPI_TABLES); - } - else - { - AdWriteTable (NewTable, NewTable->Length, - ACPI_SIG_RSDT, NewTable->OemTableId); - } - - if (ACPI_COMPARE_NAME (NewTable->Signature, ACPI_SIG_RSDT)) - { - PointerSize = sizeof (UINT32); - } - else - { - PointerSize = sizeof (UINT64); - } - - /* - * Determine the number of tables pointed to by the RSDT/XSDT. - * This is defined by the ACPI Specification to be the number of - * pointers contained within the RSDT/XSDT. The size of the pointers - * is architecture-dependent. - */ - NumTables = (NewTable->Length - sizeof (ACPI_TABLE_HEADER)) / PointerSize; - AcpiOsPrintf ("There are %u tables defined in the %4.4s\n\n", - NumTables, NewTable->Signature); - - /* Get the FADT */ - - ACPI_MOVE_32_TO_32 (TableHeader.Signature, ACPI_SIG_FADT); - AcpiOsTableOverride (&TableHeader, &NewTable); - if (NewTable) - { - AdWriteTable (NewTable, NewTable->Length, - ACPI_SIG_FADT, NewTable->OemTableId); - } - AcpiOsPrintf ("\n"); - - /* Don't bother with FACS, it is usually all zeros */ - } - - /* Always get the DSDT */ + /* Get the DSDT via table override */ ACPI_MOVE_32_TO_32 (TableHeader.Signature, ACPI_SIG_DSDT); AcpiOsTableOverride (&TableHeader, &NewTable); - if (NewTable) - { - AdWriteTable (NewTable, NewTable->Length, - ACPI_SIG_DSDT, NewTable->OemTableId); - - /* Store DSDT in the Table Manager */ - - Status = AcpiTbStoreTable (0, NewTable, NewTable->Length, - 0, &TableIndex); - if (ACPI_FAILURE (Status)) - { - fprintf (stderr, "Could not store DSDT\n"); - return (AE_NO_ACPI_TABLES); - } - } - else + if (!NewTable) { fprintf (stderr, "Could not obtain DSDT\n"); return (AE_NO_ACPI_TABLES); } -#if 0 - /* TBD: Future implementation */ - - AcpiOsPrintf ("\n"); + AdWriteTable (NewTable, NewTable->Length, + ACPI_SIG_DSDT, NewTable->OemTableId); - /* Get all SSDTs */ + /* Store DSDT in the Table Manager */ - ACPI_MOVE_32_TO_32 (TableHeader.Signature, ACPI_SIG_SSDT); - do + Status = AcpiTbStoreTable (0, NewTable, NewTable->Length, + 0, &TableIndex); + if (ACPI_FAILURE (Status)) { - NewTable = NULL; - Status = AcpiOsTableOverride (&TableHeader, &NewTable); - - } while (NewTable); -#endif + fprintf (stderr, "Could not store DSDT\n"); + return (AE_NO_ACPI_TABLES); + } return (AE_OK); } Modified: vendor-sys/acpica/dist/source/common/dmextern.c ============================================================================== --- vendor-sys/acpica/dist/source/common/dmextern.c Mon Feb 17 17:01:41 2014 (r262090) +++ vendor-sys/acpica/dist/source/common/dmextern.c Mon Feb 17 17:10:41 2014 (r262091) @@ -1265,10 +1265,16 @@ AcpiDmUnresolvedWarning ( " * were not specified. This resulting disassembler output file may not\n" " * compile because the disassembler did not know how many arguments\n" " * to assign to these methods. To specify the tables needed to resolve\n" - " * external control method references, use the one of the following\n" - " * example iASL invocations:\n" - " * iasl -e -d \n" - " * iasl -e -d \n" + " * external control method references, the -e option can be used to\n" + " * specify the filenames. Example iASL invocations:\n" + " * iasl -e ssdt1.aml ssdt2.aml ssdt3.aml -d dsdt.aml\n" + " * iasl -e dsdt.aml ssdt2.aml -d ssdt1.aml\n" + " * iasl -e ssdt*.aml -d dsdt.aml\n" + " *\n" + " * In addition, the -fe option can be used to specify a file containing\n" + " * control method external declarations with the associated method\n" + " * argument counts. Each line of the file must be of the form:\n" + " * External (, MethodObj, )\n" " */\n", AcpiGbl_NumExternalMethods); } @@ -1279,10 +1285,15 @@ AcpiDmUnresolvedWarning ( AcpiOsPrintf (" /*\n" " * iASL Warning: There were %u external control methods found during\n" " * disassembly, but only %u %s resolved (%u unresolved). Additional\n" - " * ACPI tables are required to properly disassemble the code. This\n" + " * ACPI tables may be required to properly disassemble the code. This\n" " * resulting disassembler output file may not compile because the\n" " * disassembler did not know how many arguments to assign to the\n" " * unresolved methods.\n" + " *\n" + " * If necessary, the -fe option can be used to specify a file containing\n" + " * control method external declarations with the associated method\n" + " * argument counts. Each line of the file must be of the form:\n" + " * External (, MethodObj, )\n" " */\n", AcpiGbl_NumExternalMethods, AcpiGbl_ResolvedExternalMethods, (AcpiGbl_ResolvedExternalMethods > 1 ? "were" : "was"), @@ -1301,10 +1312,16 @@ AcpiDmUnresolvedWarning ( "were not specified. The resulting disassembler output file may not\n" "compile because the disassembler did not know how many arguments\n" "to assign to these methods. To specify the tables needed to resolve\n" - "external control method references, use the one of the following\n" - "example iASL invocations:\n" - " iasl -e -d \n" - " iasl -e -d \n", + "external control method references, the -e option can be used to\n" + "specify the filenames. Example iASL invocations:\n" + " iasl -e ssdt1.aml ssdt2.aml ssdt3.aml -d dsdt.aml\n" + " iasl -e dsdt.aml ssdt2.aml -d ssdt1.aml\n" + " iasl -e ssdt*.aml -d dsdt.aml\n" + "\n" + "In addition, the -fe option can be used to specify a file containing\n" + "control method external declarations with the associated method\n" + "argument counts. Each line of the file must be of the form:\n" + " External (, MethodObj, )\n", AcpiGbl_NumExternalMethods); } else if (AcpiGbl_NumExternalMethods != AcpiGbl_ResolvedExternalMethods) @@ -1314,10 +1331,15 @@ AcpiDmUnresolvedWarning ( fprintf (stderr, "\n" "iASL Warning: There were %u external control methods found during\n" "disassembly, but only %u %s resolved (%u unresolved). Additional\n" - "ACPI tables are required to properly disassemble the code. The\n" + "ACPI tables may be required to properly disassemble the code. The\n" "resulting disassembler output file may not compile because the\n" "disassembler did not know how many arguments to assign to the\n" - "unresolved methods.\n", + "unresolved methods.\n" + "\n" + "If necessary, the -fe option can be used to specify a file containing\n" + "control method external declarations with the associated method\n" + "argument counts. Each line of the file must be of the form:\n" + " External (, MethodObj, )\n", AcpiGbl_NumExternalMethods, AcpiGbl_ResolvedExternalMethods, (AcpiGbl_ResolvedExternalMethods > 1 ? "were" : "was"), (AcpiGbl_NumExternalMethods - AcpiGbl_ResolvedExternalMethods)); Modified: vendor-sys/acpica/dist/source/common/dmtbinfo.c ============================================================================== --- vendor-sys/acpica/dist/source/common/dmtbinfo.c Mon Feb 17 17:01:41 2014 (r262090) +++ vendor-sys/acpica/dist/source/common/dmtbinfo.c Mon Feb 17 17:10:41 2014 (r262091) @@ -1940,7 +1940,7 @@ ACPI_DMTABLE_INFO AcpiDmTableI ACPI_DMTABLE_INFO AcpiDmTableInfoSpmi[] = { {ACPI_DMT_UINT8, ACPI_SPMI_OFFSET (InterfaceType), "Interface Type", 0}, - {ACPI_DMT_UINT8, ACPI_SPMI_OFFSET (Reserved), "Reserved", 0}, + {ACPI_DMT_UINT8, ACPI_SPMI_OFFSET (Reserved), "Reserved", DT_NON_ZERO}, /* Value must be 1 */ {ACPI_DMT_UINT16, ACPI_SPMI_OFFSET (SpecRevision), "IPMI Spec Version", 0}, {ACPI_DMT_UINT8, ACPI_SPMI_OFFSET (InterruptType), "Interrupt Type", 0}, {ACPI_DMT_UINT8, ACPI_SPMI_OFFSET (GpeNumber), "GPE Number", 0}, Modified: vendor-sys/acpica/dist/source/compiler/aslcompiler.h ============================================================================== --- vendor-sys/acpica/dist/source/compiler/aslcompiler.h Mon Feb 17 17:01:41 2014 (r262090) +++ vendor-sys/acpica/dist/source/compiler/aslcompiler.h Mon Feb 17 17:10:41 2014 (r262091) @@ -280,6 +280,10 @@ ApCheckRegMethod ( * aslerror - error handling/reporting */ void +AslAbort ( + void); + +void AslError ( UINT8 Level, UINT8 MessageId, @@ -703,10 +707,6 @@ TrLinkPeerNodes ( * aslfiles - File I/O support */ void -AslAbort ( - void); - -void FlAddIncludeDirectory ( char *Dir); Modified: vendor-sys/acpica/dist/source/compiler/aslerror.c ============================================================================== --- vendor-sys/acpica/dist/source/compiler/aslerror.c Mon Feb 17 17:01:41 2014 (r262090) +++ vendor-sys/acpica/dist/source/compiler/aslerror.c Mon Feb 17 17:10:41 2014 (r262091) @@ -56,6 +56,36 @@ AeAddToErrorLog ( /******************************************************************************* * + * FUNCTION: AslAbort + * + * PARAMETERS: None + * + * RETURN: None + * + * DESCRIPTION: Dump the error log and abort the compiler. Used for serious + * I/O errors. + * + ******************************************************************************/ + +void +AslAbort ( + void) +{ + + AePrintErrorLog (ASL_FILE_STDERR); + if (Gbl_DebugFlag) + { + /* Print error summary to stdout also */ + + AePrintErrorLog (ASL_FILE_STDOUT); + } + + exit (1); +} + + +/******************************************************************************* + * * FUNCTION: AeClearErrorLog * * PARAMETERS: None @@ -817,7 +847,8 @@ AslError ( /* Check if user wants to ignore this exception */ - if (AslIsExceptionDisabled (Level, MessageId)) + if (Gbl_AllExceptionsDisabled || + AslIsExceptionDisabled (Level, MessageId)) { return; } Modified: vendor-sys/acpica/dist/source/compiler/aslfileio.c ============================================================================== --- vendor-sys/acpica/dist/source/compiler/aslfileio.c Mon Feb 17 17:01:41 2014 (r262090) +++ vendor-sys/acpica/dist/source/compiler/aslfileio.c Mon Feb 17 17:10:41 2014 (r262091) @@ -46,35 +46,9 @@ #define _COMPONENT ACPI_COMPILER ACPI_MODULE_NAME ("aslfileio") - -/******************************************************************************* - * - * FUNCTION: AslAbort - * - * PARAMETERS: None - * - * RETURN: None - * - * DESCRIPTION: Dump the error log and abort the compiler. Used for serious - * I/O errors. - * - ******************************************************************************/ - -void -AslAbort ( - void) -{ - - AePrintErrorLog (ASL_FILE_STDERR); - if (Gbl_DebugFlag) - { - /* Print error summary to stdout also */ - - AePrintErrorLog (ASL_FILE_STDOUT); - } - - exit (1); -} +long +UtGetFileSize ( + FILE *fp); /******************************************************************************* @@ -141,13 +115,73 @@ FlOpenFile ( /******************************************************************************* * + * FUNCTION: UtGetFileSize + * + * PARAMETERS: fp - Open file handle + * + * RETURN: File Size. -1 on error. + * + * DESCRIPTION: Get current file size. Uses seek-to-EOF. File must be open. + * TBD: This function should be used to replace other similar + * functions in ACPICA. + * + ******************************************************************************/ + +long +UtGetFileSize ( + FILE *fp) +{ + long FileSize; + long CurrentOffset; + + + CurrentOffset = ftell (fp); + if (CurrentOffset < 0) + { + goto OffsetError; + } + + if (fseek (fp, 0, SEEK_END)) + { + goto SeekError; + } + + FileSize = ftell (fp); + if (FileSize < 0) + { + goto OffsetError; + } + + /* Restore file pointer */ + + if (fseek (fp, CurrentOffset, SEEK_SET)) + { + goto SeekError; + } + + return (FileSize); + + +OffsetError: + perror ("Could not get file offset"); + return (-1); + +SeekError: + perror ("Could not seek file"); + return (-1); +} + + +/******************************************************************************* + * * FUNCTION: FlGetFileSize * * PARAMETERS: FileId - Index into file info array * * RETURN: File Size * - * DESCRIPTION: Get current file size. Uses seek-to-EOF. File must be open. + * DESCRIPTION: Get current file size. Uses common seek-to-EOF function. + * File must be open. Aborts compiler on error. * ******************************************************************************/ @@ -155,21 +189,16 @@ UINT32 FlGetFileSize ( UINT32 FileId) { - FILE *fp; - UINT32 FileSize; - long Offset; - + long FileSize; - fp = Gbl_Files[FileId].Handle; - Offset = ftell (fp); - fseek (fp, 0, SEEK_END); - FileSize = (UINT32) ftell (fp); - - /* Restore file pointer */ + FileSize = UtGetFileSize (Gbl_Files[FileId].Handle); + if (FileSize == -1) + { + AslAbort(); + } - fseek (fp, Offset, SEEK_SET); - return (FileSize); + return ((UINT32) FileSize); } Modified: vendor-sys/acpica/dist/source/compiler/aslglobal.h ============================================================================== --- vendor-sys/acpica/dist/source/compiler/aslglobal.h Mon Feb 17 17:01:41 2014 (r262090) +++ vendor-sys/acpica/dist/source/compiler/aslglobal.h Mon Feb 17 17:10:41 2014 (r262091) @@ -159,7 +159,6 @@ ASL_EXTERN BOOLEAN ASL_ ASL_EXTERN BOOLEAN ASL_INIT_GLOBAL (Gbl_WarningsAsErrors, FALSE); ASL_EXTERN BOOLEAN ASL_INIT_GLOBAL (Gbl_NoResourceChecking, FALSE); ASL_EXTERN BOOLEAN ASL_INIT_GLOBAL (Gbl_DisasmFlag, FALSE); -ASL_EXTERN BOOLEAN ASL_INIT_GLOBAL (Gbl_GetAllTables, FALSE); ASL_EXTERN BOOLEAN ASL_INIT_GLOBAL (Gbl_IntegerOptimizationFlag, TRUE); ASL_EXTERN BOOLEAN ASL_INIT_GLOBAL (Gbl_ReferenceOptimizationFlag, TRUE); ASL_EXTERN BOOLEAN ASL_INIT_GLOBAL (Gbl_DisplayRemarks, TRUE); @@ -170,6 +169,7 @@ ASL_EXTERN BOOLEAN ASL_ ASL_EXTERN BOOLEAN ASL_INIT_GLOBAL (Gbl_VerboseTemplates, FALSE); ASL_EXTERN BOOLEAN ASL_INIT_GLOBAL (Gbl_DoTemplates, FALSE); ASL_EXTERN BOOLEAN ASL_INIT_GLOBAL (Gbl_CompileGeneric, FALSE); +ASL_EXTERN BOOLEAN ASL_INIT_GLOBAL (Gbl_AllExceptionsDisabled, FALSE); #define HEX_OUTPUT_NONE 0 Modified: vendor-sys/acpica/dist/source/compiler/aslmain.c ============================================================================== --- vendor-sys/acpica/dist/source/compiler/aslmain.c Mon Feb 17 17:01:41 2014 (r262090) +++ vendor-sys/acpica/dist/source/compiler/aslmain.c Mon Feb 17 17:10:41 2014 (r262091) @@ -158,7 +158,6 @@ Usage ( ACPI_OPTION ("", " (Obtain DSDT from current system if no input file)"); ACPI_OPTION ("-e ", "Include ACPI table(s) for external symbol resolution"); ACPI_OPTION ("-fe ", "Specify external symbol declaration file"); - ACPI_OPTION ("-g", "Get ACPI tables and write to files (*.dat)"); ACPI_OPTION ("-in", "Ignore NoOp opcodes"); ACPI_OPTION ("-vt", "Dump binary table data in hex format within output file"); @@ -319,16 +318,6 @@ main ( /* Perform global actions first/only */ - if (Gbl_GetAllTables) - { - Status = AslDoOneFile (NULL); - if (ACPI_FAILURE (Status)) - { - return (-1); - } - return (0); - } - if (Gbl_DisassembleAll) { while (argv[Index1]) Modified: vendor-sys/acpica/dist/source/compiler/aslmessages.h ============================================================================== --- vendor-sys/acpica/dist/source/compiler/aslmessages.h Mon Feb 17 17:01:41 2014 (r262090) +++ vendor-sys/acpica/dist/source/compiler/aslmessages.h Mon Feb 17 17:10:41 2014 (r262091) @@ -445,7 +445,7 @@ char *AslMessages /* ASL_MSG_INVALID_FIELD_NAME */ "Invalid Field Name", /* ASL_MSG_INVALID_HEX_INTEGER */ "Invalid hex integer constant", /* ASL_MSG_OEM_TABLE */ "OEM table - unknown contents", -/* ASL_MSG_RESERVED_VALUE */ "Reserved field must be zero", +/* ASL_MSG_RESERVED_VALUE */ "Reserved field", /* ASL_MSG_UNKNOWN_LABEL */ "Label is undefined", /* ASL_MSG_UNKNOWN_SUBTABLE */ "Unknown subtable type", /* ASL_MSG_UNKNOWN_TABLE */ "Unknown ACPI table signature", Modified: vendor-sys/acpica/dist/source/compiler/asloptions.c ============================================================================== --- vendor-sys/acpica/dist/source/compiler/asloptions.c Mon Feb 17 17:01:41 2014 (r262090) +++ vendor-sys/acpica/dist/source/compiler/asloptions.c Mon Feb 17 17:10:41 2014 (r262091) @@ -118,8 +118,7 @@ AslCommandLine ( /* Next parameter must be the input filename */ if (!argv[AcpiGbl_Optind] && - !Gbl_DisasmFlag && - !Gbl_GetAllTables) + !Gbl_DisasmFlag) { printf ("Missing input filename\n"); BadCommandLine = TRUE; @@ -318,9 +317,8 @@ AslDoOptions ( case 'g': /* Get all ACPI tables */ - Gbl_GetAllTables = TRUE; - Gbl_DoCompile = FALSE; - break; + printf ("-g option is deprecated, use acpidump utility instead\n"); + exit (1); case 'h': Modified: vendor-sys/acpica/dist/source/compiler/aslpredef.c ============================================================================== --- vendor-sys/acpica/dist/source/compiler/aslpredef.c Mon Feb 17 17:01:41 2014 (r262090) +++ vendor-sys/acpica/dist/source/compiler/aslpredef.c Mon Feb 17 17:10:41 2014 (r262091) @@ -251,10 +251,16 @@ ApCheckPredefinedReturnValue ( const ACPI_PREDEFINED_INFO *ThisName; - /* Check parent method for a match against the predefined name list */ - + /* + * Check parent method for a match against the predefined name list. + * + * Note: Disable compiler errors/warnings because any errors will be + * caught when analyzing the parent method. Eliminates duplicate errors. + */ + Gbl_AllExceptionsDisabled = TRUE; Index = ApCheckForPredefinedName (MethodInfo->Op, MethodInfo->Op->Asl.NameSeg); + Gbl_AllExceptionsDisabled = FALSE; switch (Index) { Modified: vendor-sys/acpica/dist/source/compiler/aslprepkg.c ============================================================================== --- vendor-sys/acpica/dist/source/compiler/aslprepkg.c Mon Feb 17 17:01:41 2014 (r262090) +++ vendor-sys/acpica/dist/source/compiler/aslprepkg.c Mon Feb 17 17:10:41 2014 (r262091) @@ -169,7 +169,7 @@ ApCheckPackage ( { case ACPI_PTYPE1_FIXED: /* - * The package count is fixed and there are no sub-packages + * The package count is fixed and there are no subpackages * * If package is too small, exit. * If package is larger than expected, issue warning but continue @@ -194,7 +194,7 @@ ApCheckPackage ( case ACPI_PTYPE1_VAR: /* - * The package count is variable, there are no sub-packages, + * The package count is variable, there are no subpackages, * and all elements must be of the same type */ for (i = 0; i < Count; i++) @@ -207,7 +207,7 @@ ApCheckPackage ( case ACPI_PTYPE1_OPTION: /* - * The package count is variable, there are no sub-packages. + * The package count is variable, there are no subpackages. * There are a fixed number of required elements, and a variable * number of optional elements. * @@ -251,7 +251,7 @@ ApCheckPackage ( Op = Op->Asl.Next; Count--; - /* Examine the sub-packages */ + /* Examine the subpackages */ ApCheckPackageList (Predefined->Info.Name, Op, Package, 1, Count); @@ -259,7 +259,7 @@ ApCheckPackage ( case ACPI_PTYPE2_PKG_COUNT: - /* First element is the (Integer) count of sub-packages to follow */ + /* First element is the (Integer) count of subpackages to follow */ Status = ApCheckObjectType (Predefined->Info.Name, Op, ACPI_RTYPE_INTEGER, 0); @@ -283,7 +283,7 @@ ApCheckPackage ( Op = Op->Asl.Next; - /* Examine the sub-packages */ + /* Examine the subpackages */ ApCheckPackageList (Predefined->Info.Name, Op, Package, 1, Count); @@ -296,10 +296,10 @@ ApCheckPackage ( case ACPI_PTYPE2_FIX_VAR: /* * These types all return a single Package that consists of a - * variable number of sub-Packages. + * variable number of subpackages. */ - /* Examine the sub-packages */ + /* Examine the subpackages */ ApCheckPackageList (Predefined->Info.Name, Op, Package, 0, Count); @@ -494,7 +494,7 @@ ApCheckPackageList ( case ACPI_PTYPE2_FIXED: - /* Each sub-package has a fixed length */ + /* Each subpackage has a fixed length */ ExpectedCount = Package->RetInfo2.Count; if (Count < ExpectedCount) @@ -517,7 +517,7 @@ ApCheckPackageList ( case ACPI_PTYPE2_MIN: - /* Each sub-package has a variable but minimum length */ + /* Each subpackage has a variable but minimum length */ ExpectedCount = Package->RetInfo.Count1; if (Count < ExpectedCount) @@ -527,7 +527,7 @@ ApCheckPackageList ( break; } - /* Check the type of each sub-package element */ + /* Check the type of each subpackage element */ ApCheckPackageElements (PredefinedName, Op, Package->RetInfo.ObjectType1, Count, 0, 0); @@ -576,7 +576,7 @@ ApCheckPackageList ( Count = ExpectedCount; } - /* Check the type of each sub-package element */ + /* Check the type of each subpackage element */ Op = Op->Asl.Next; ApCheckPackageElements (PredefinedName, Op, Modified: vendor-sys/acpica/dist/source/compiler/aslstartup.c ============================================================================== --- vendor-sys/acpica/dist/source/compiler/aslstartup.c Mon Feb 17 17:01:41 2014 (r262090) +++ vendor-sys/acpica/dist/source/compiler/aslstartup.c Mon Feb 17 17:10:41 2014 (r262091) @@ -251,7 +251,7 @@ AslDoDisassembly ( AcpiGbl_DbOpt_disasm = TRUE; Status = AdAmlDisassemble (AslToFile, Gbl_Files[ASL_FILE_INPUT].Filename, Gbl_OutputFilenamePrefix, - &Gbl_Files[ASL_FILE_INPUT].Filename, Gbl_GetAllTables); + &Gbl_Files[ASL_FILE_INPUT].Filename); if (ACPI_FAILURE (Status)) { return (Status); @@ -331,7 +331,7 @@ AslDoOneFile ( /* * AML Disassembly (Optional) */ - if (Gbl_DisasmFlag || Gbl_GetAllTables) + if (Gbl_DisasmFlag) { Status = AslDoDisassembly (); if (Status != AE_CTRL_CONTINUE) Modified: vendor-sys/acpica/dist/source/compiler/asltransform.c ============================================================================== --- vendor-sys/acpica/dist/source/compiler/asltransform.c Mon Feb 17 17:01:41 2014 (r262090) +++ vendor-sys/acpica/dist/source/compiler/asltransform.c Mon Feb 17 17:10:41 2014 (r262091) @@ -450,10 +450,6 @@ TrDoSwitch ( { /* Add an ELSE to complete the previous CASE */ - if (!Conditional) - { - return; - } NewOp = TrCreateLeafNode (PARSEOP_ELSE); NewOp->Asl.Parent = Conditional->Asl.Parent; TrAmlInitLineNumbers (NewOp, NewOp->Asl.Parent); @@ -620,11 +616,6 @@ TrDoSwitch ( { /* Convert the DEFAULT node to an ELSE */ - if (!Conditional) - { - return; - } - TrAmlInitNode (DefaultOp, PARSEOP_ELSE); DefaultOp->Asl.Parent = Conditional->Asl.Parent; Modified: vendor-sys/acpica/dist/source/compiler/dtfield.c ============================================================================== --- vendor-sys/acpica/dist/source/compiler/dtfield.c Mon Feb 17 17:01:41 2014 (r262090) +++ vendor-sys/acpica/dist/source/compiler/dtfield.c Mon Feb 17 17:10:41 2014 (r262091) @@ -311,21 +311,37 @@ DtCompileInteger ( return; } - /* Ensure that reserved fields are set to zero */ - /* TBD: should we set to zero, or just make this an ERROR? */ - /* TBD: Probably better to use a flag */ + /* + * Ensure that reserved fields are set properly. Note: uses + * the DT_NON_ZERO flag to indicate that the reserved value + * must be exactly one. Otherwise, the value must be zero. + * This is sufficient for now. + */ + + /* TBD: Should use a flag rather than compare "Reserved" */ - if (!ACPI_STRCMP (Field->Name, "Reserved") && - (Value != 0)) + if (!ACPI_STRCMP (Field->Name, "Reserved")) { - DtError (ASL_WARNING, ASL_MSG_RESERVED_VALUE, Field, - "Setting to zero"); - Value = 0; + if (Flags & DT_NON_ZERO) + { + if (Value != 1) + { + DtError (ASL_WARNING, ASL_MSG_RESERVED_VALUE, Field, + "Must be one, setting to one"); + Value = 1; + } + } + else if (Value != 0) + { + DtError (ASL_WARNING, ASL_MSG_RESERVED_VALUE, Field, + "Must be zero, setting to zero"); + Value = 0; + } } /* Check if the value must be non-zero */ - if ((Value == 0) && (Flags & DT_NON_ZERO)) + else if ((Flags & DT_NON_ZERO) && (Value == 0)) { DtError (ASL_ERROR, ASL_MSG_ZERO_VALUE, Field, NULL); } Modified: vendor-sys/acpica/dist/source/compiler/dttemplate.h ============================================================================== --- vendor-sys/acpica/dist/source/compiler/dttemplate.h Mon Feb 17 17:01:41 2014 (r262090) +++ vendor-sys/acpica/dist/source/compiler/dttemplate.h Mon Feb 17 17:10:41 2014 (r262091) @@ -897,10 +897,10 @@ const unsigned char TemplateSpcr[] = const unsigned char TemplateSpmi[] = { 0x53,0x50,0x4D,0x49,0x41,0x00,0x00,0x00, /* 00000000 "SPMIA..." */ - 0x04,0xED,0x49,0x4E,0x54,0x45,0x4C,0x20, /* 00000008 "..INTEL " */ + 0x04,0x00,0x49,0x4E,0x54,0x45,0x4C,0x20, /* 00000008 "..INTEL " */ 0x54,0x45,0x4D,0x50,0x4C,0x41,0x54,0x45, /* 00000010 "TEMPLATE" */ 0x00,0x00,0x00,0x00,0x49,0x4E,0x54,0x4C, /* 00000018 "....INTL" */ - 0x28,0x05,0x10,0x20,0x00,0x00,0x00,0x00, /* 00000020 "(.. ...." */ + 0x14,0x01,0x14,0x20,0x00,0x01,0x00,0x00, /* 00000020 "... ...." */ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 00000028 "........" */ 0x00,0x08,0x00,0x01,0x00,0x00,0x00,0x00, /* 00000030 "........" */ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 00000038 "........" */ Modified: vendor-sys/acpica/dist/source/compiler/prmacros.c ============================================================================== --- vendor-sys/acpica/dist/source/compiler/prmacros.c Mon Feb 17 17:01:41 2014 (r262090) +++ vendor-sys/acpica/dist/source/compiler/prmacros.c Mon Feb 17 17:10:41 2014 (r262091) @@ -360,7 +360,7 @@ PrAddMacro ( if (ArgCount >= PR_MAX_MACRO_ARGS) { PrError (ASL_ERROR, ASL_MSG_TOO_MANY_ARGUMENTS, TokenOffset); - return; + goto ErrorExit; } } @@ -400,7 +400,7 @@ PrAddMacro ( PrError (ASL_ERROR, ASL_MSG_TOO_MANY_ARGUMENTS, THIS_TOKEN_OFFSET (Token)); - return; + goto ErrorExit; } break; } @@ -432,7 +432,7 @@ AddMacroToList: THIS_TOKEN_OFFSET (Name)); } - return; + goto ErrorExit; } DbgPrint (ASL_DEBUG_OUTPUT, PR_PREFIX_ID @@ -451,6 +451,13 @@ AddMacroToList: DefineInfo->Args = Args; DefineInfo->ArgCount = ArgCount; } + + return; + + +ErrorExit: + ACPI_FREE (Args); + return; } Modified: vendor-sys/acpica/dist/source/components/debugger/dbdisply.c ============================================================================== --- vendor-sys/acpica/dist/source/components/debugger/dbdisply.c Mon Feb 17 17:01:41 2014 (r262090) +++ vendor-sys/acpica/dist/source/components/debugger/dbdisply.c Mon Feb 17 17:10:41 2014 (r262091) @@ -303,6 +303,10 @@ AcpiDbDecodeAndDisplayObject ( /* Is not a recognizeable object */ + AcpiOsPrintf ( + "Not a known ACPI internal object, descriptor type %2.2X\n", + ACPI_GET_DESCRIPTOR_TYPE (ObjPtr)); + Size = 16; if (AcpiOsReadable (ObjPtr, 64)) { Modified: vendor-sys/acpica/dist/source/components/dispatcher/dsinit.c ============================================================================== --- vendor-sys/acpica/dist/source/components/dispatcher/dsinit.c Mon Feb 17 17:01:41 2014 (r262090) +++ vendor-sys/acpica/dist/source/components/dispatcher/dsinit.c Mon Feb 17 17:10:41 2014 (r262091) @@ -52,6 +52,7 @@ #define _COMPONENT ACPI_DISPATCHER ACPI_MODULE_NAME ("dsinit") + /* Local prototypes */ static ACPI_STATUS @@ -91,8 +92,8 @@ AcpiDsInitOneObject ( { ACPI_INIT_WALK_INFO *Info = (ACPI_INIT_WALK_INFO *) Context; ACPI_NAMESPACE_NODE *Node = (ACPI_NAMESPACE_NODE *) ObjHandle; - ACPI_OBJECT_TYPE Type; ACPI_STATUS Status; + ACPI_OPERAND_OBJECT *ObjDesc; ACPI_FUNCTION_ENTRY (); @@ -111,9 +112,7 @@ AcpiDsInitOneObject ( /* And even then, we are only interested in a few object types */ - Type = AcpiNsGetType (ObjHandle); - - switch (Type) + switch (AcpiNsGetType (ObjHandle)) { case ACPI_TYPE_REGION: @@ -129,8 +128,45 @@ AcpiDsInitOneObject ( break; case ACPI_TYPE_METHOD: - + /* + * Auto-serialization support. We will examine each method that is + * NotSerialized to determine if it creates any Named objects. If + * it does, it will be marked serialized to prevent problems if + * the method is entered by two or more threads and an attempt is + * made to create the same named object twice -- which results in + * an AE_ALREADY_EXISTS exception and method abort. + */ Info->MethodCount++; + ObjDesc = AcpiNsGetAttachedObject (Node); + if (!ObjDesc) + { + break; + } + + /* Ignore if already serialized */ + + if (ObjDesc->Method.InfoFlags & ACPI_METHOD_SERIALIZED) + { + Info->SerialMethodCount++; + break; + } + + if (AcpiGbl_AutoSerializeMethods) + { + /* Parse/scan method and serialize it if necessary */ + + AcpiDsAutoSerializeMethod (Node, ObjDesc); + if (ObjDesc->Method.InfoFlags & ACPI_METHOD_SERIALIZED) + { + /* Method was just converted to Serialized */ + + Info->SerialMethodCount++; + Info->SerializedMethodCount++; + break; + } *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-vendor@FreeBSD.ORG Mon Feb 17 17:11:33 2014 Return-Path: Delivered-To: svn-src-vendor@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 38980FFA; Mon, 17 Feb 2014 17:11:33 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 0ABA51899; Mon, 17 Feb 2014 17:11:33 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s1HHBWrd055521; Mon, 17 Feb 2014 17:11:32 GMT (envelope-from jkim@svn.freebsd.org) Received: (from jkim@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s1HHBW0L055520; Mon, 17 Feb 2014 17:11:32 GMT (envelope-from jkim@svn.freebsd.org) Message-Id: <201402171711.s1HHBW0L055520@svn.freebsd.org> From: Jung-uk Kim Date: Mon, 17 Feb 2014 17:11:32 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org Subject: svn commit: r262092 - vendor-sys/acpica/20140214 X-SVN-Group: vendor-sys MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-vendor@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: SVN commit messages for the vendor work area tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Feb 2014 17:11:33 -0000 Author: jkim Date: Mon Feb 17 17:11:32 2014 New Revision: 262092 URL: http://svnweb.freebsd.org/changeset/base/262092 Log: Tag ACPICA 20140214. Added: vendor-sys/acpica/20140214/ - copied from r262091, vendor-sys/acpica/dist/ From owner-svn-src-vendor@FreeBSD.ORG Tue Feb 18 16:23:16 2014 Return-Path: Delivered-To: svn-src-vendor@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 6D05F848; Tue, 18 Feb 2014 16:23:16 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 54BD317DD; Tue, 18 Feb 2014 16:23:16 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s1IGNGqA034345; Tue, 18 Feb 2014 16:23:16 GMT (envelope-from emaste@svn.freebsd.org) Received: (from emaste@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s1IGNBg8034318; Tue, 18 Feb 2014 16:23:11 GMT (envelope-from emaste@svn.freebsd.org) Message-Id: <201402181623.s1IGNBg8034318@svn.freebsd.org> From: Ed Maste Date: Tue, 18 Feb 2014 16:23:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org Subject: svn commit: r262182 - in vendor/lldb/dist: include/lldb include/lldb/API include/lldb/Breakpoint include/lldb/Core include/lldb/DataFormatters include/lldb/Expression include/lldb/Host include/lldb... X-SVN-Group: vendor MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-vendor@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: SVN commit messages for the vendor work area tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Feb 2014 16:23:16 -0000 Author: emaste Date: Tue Feb 18 16:23:10 2014 New Revision: 262182 URL: http://svnweb.freebsd.org/changeset/base/262182 Log: Import lldb as of SVN r201577 (git 2bdc2f6) (A number of files not required for the FreeBSD build have been removed.) Sponsored by: DARPA, AFRL Added: vendor/lldb/dist/include/lldb/API/SBQueue.h (contents, props changed) vendor/lldb/dist/include/lldb/API/SBQueueItem.h (contents, props changed) vendor/lldb/dist/include/lldb/Core/IOHandler.h (contents, props changed) vendor/lldb/dist/include/lldb/DataFormatters/FormattersContainer.h (contents, props changed) vendor/lldb/dist/include/lldb/Host/Editline.h (contents, props changed) vendor/lldb/dist/include/lldb/Host/HostGetOpt.h (contents, props changed) vendor/lldb/dist/include/lldb/Target/Queue.h (contents, props changed) vendor/lldb/dist/include/lldb/Target/QueueItem.h (contents, props changed) vendor/lldb/dist/include/lldb/Target/QueueList.h (contents, props changed) vendor/lldb/dist/include/lldb/Target/SectionLoadHistory.h (contents, props changed) vendor/lldb/dist/source/API/SBQueue.cpp (contents, props changed) vendor/lldb/dist/source/API/SBQueueItem.cpp (contents, props changed) vendor/lldb/dist/source/Commands/CommandObjectGUI.cpp (contents, props changed) vendor/lldb/dist/source/Commands/CommandObjectGUI.h (contents, props changed) vendor/lldb/dist/source/Core/IOHandler.cpp (contents, props changed) vendor/lldb/dist/source/Host/common/Editline.cpp (contents, props changed) vendor/lldb/dist/source/Plugins/Process/FreeBSD/FreeBSDThread.cpp (contents, props changed) vendor/lldb/dist/source/Plugins/Process/FreeBSD/FreeBSDThread.h (contents, props changed) vendor/lldb/dist/source/Target/Queue.cpp (contents, props changed) vendor/lldb/dist/source/Target/QueueItem.cpp (contents, props changed) vendor/lldb/dist/source/Target/QueueList.cpp (contents, props changed) vendor/lldb/dist/source/Target/SectionLoadHistory.cpp (contents, props changed) vendor/lldb/dist/tools/lldb-platform/exports Deleted: vendor/lldb/dist/include/lldb/API/SBInputReader.h vendor/lldb/dist/include/lldb/Core/InputReader.h vendor/lldb/dist/include/lldb/Core/InputReaderEZ.h vendor/lldb/dist/include/lldb/Core/InputReaderStack.h vendor/lldb/dist/include/lldb/DataFormatters/FormatNavigator.h vendor/lldb/dist/source/API/SBInputReader.cpp vendor/lldb/dist/source/Core/InputReader.cpp vendor/lldb/dist/source/Core/InputReaderEZ.cpp vendor/lldb/dist/source/Core/InputReaderStack.cpp vendor/lldb/dist/tools/driver/ELWrapper.cpp vendor/lldb/dist/tools/driver/ELWrapper.h vendor/lldb/dist/tools/driver/GetOptWrapper.cpp vendor/lldb/dist/tools/driver/GetOptWrapper.h vendor/lldb/dist/tools/driver/IOChannel.cpp vendor/lldb/dist/tools/driver/IOChannel.h Modified: vendor/lldb/dist/include/lldb/API/LLDB.h vendor/lldb/dist/include/lldb/API/SBAddress.h vendor/lldb/dist/include/lldb/API/SBCommandInterpreter.h vendor/lldb/dist/include/lldb/API/SBDebugger.h vendor/lldb/dist/include/lldb/API/SBDefines.h vendor/lldb/dist/include/lldb/API/SBError.h vendor/lldb/dist/include/lldb/API/SBModule.h vendor/lldb/dist/include/lldb/API/SBProcess.h vendor/lldb/dist/include/lldb/API/SBTarget.h vendor/lldb/dist/include/lldb/API/SBThread.h vendor/lldb/dist/include/lldb/API/SBType.h vendor/lldb/dist/include/lldb/API/SBTypeFormat.h vendor/lldb/dist/include/lldb/Breakpoint/Breakpoint.h vendor/lldb/dist/include/lldb/Breakpoint/BreakpointLocation.h vendor/lldb/dist/include/lldb/Breakpoint/BreakpointLocationList.h vendor/lldb/dist/include/lldb/Core/ArchSpec.h vendor/lldb/dist/include/lldb/Core/Communication.h vendor/lldb/dist/include/lldb/Core/ConnectionFileDescriptor.h vendor/lldb/dist/include/lldb/Core/Debugger.h vendor/lldb/dist/include/lldb/Core/Disassembler.h vendor/lldb/dist/include/lldb/Core/MappedHash.h vendor/lldb/dist/include/lldb/Core/Module.h vendor/lldb/dist/include/lldb/Core/Opcode.h vendor/lldb/dist/include/lldb/Core/SourceManager.h vendor/lldb/dist/include/lldb/Core/StreamAsynchronousIO.h vendor/lldb/dist/include/lldb/Core/StringList.h vendor/lldb/dist/include/lldb/Core/ValueObject.h vendor/lldb/dist/include/lldb/Core/ValueObjectList.h vendor/lldb/dist/include/lldb/DataFormatters/CXXFormatterFunctions.h vendor/lldb/dist/include/lldb/DataFormatters/FormatManager.h vendor/lldb/dist/include/lldb/DataFormatters/TypeCategory.h vendor/lldb/dist/include/lldb/DataFormatters/TypeCategoryMap.h vendor/lldb/dist/include/lldb/DataFormatters/TypeFormat.h vendor/lldb/dist/include/lldb/DataFormatters/TypeSynthetic.h vendor/lldb/dist/include/lldb/DataFormatters/ValueObjectPrinter.h vendor/lldb/dist/include/lldb/Expression/ClangFunction.h vendor/lldb/dist/include/lldb/Expression/IRForTarget.h vendor/lldb/dist/include/lldb/Host/File.h vendor/lldb/dist/include/lldb/Host/FileSpec.h vendor/lldb/dist/include/lldb/Host/Host.h vendor/lldb/dist/include/lldb/Host/SocketAddress.h vendor/lldb/dist/include/lldb/Interpreter/CommandInterpreter.h vendor/lldb/dist/include/lldb/Interpreter/PythonDataObjects.h vendor/lldb/dist/include/lldb/Interpreter/ScriptInterpreter.h vendor/lldb/dist/include/lldb/Interpreter/ScriptInterpreterPython.h vendor/lldb/dist/include/lldb/Symbol/FuncUnwinders.h vendor/lldb/dist/include/lldb/Symbol/Function.h vendor/lldb/dist/include/lldb/Symbol/ObjectFile.h vendor/lldb/dist/include/lldb/Symbol/Symbol.h vendor/lldb/dist/include/lldb/Symbol/SymbolContext.h vendor/lldb/dist/include/lldb/Symbol/Type.h vendor/lldb/dist/include/lldb/Symbol/UnwindTable.h vendor/lldb/dist/include/lldb/Target/DynamicLoader.h vendor/lldb/dist/include/lldb/Target/ExecutionContext.h vendor/lldb/dist/include/lldb/Target/Platform.h vendor/lldb/dist/include/lldb/Target/Process.h vendor/lldb/dist/include/lldb/Target/SectionLoadList.h vendor/lldb/dist/include/lldb/Target/SystemRuntime.h vendor/lldb/dist/include/lldb/Target/Target.h vendor/lldb/dist/include/lldb/Target/Thread.h vendor/lldb/dist/include/lldb/Target/ThreadList.h vendor/lldb/dist/include/lldb/Target/ThreadPlanStepInRange.h vendor/lldb/dist/include/lldb/Target/UnwindAssembly.h vendor/lldb/dist/include/lldb/Utility/Iterable.h vendor/lldb/dist/include/lldb/lldb-enumerations.h vendor/lldb/dist/include/lldb/lldb-forward.h vendor/lldb/dist/include/lldb/lldb-private-enumerations.h vendor/lldb/dist/include/lldb/lldb-private-log.h vendor/lldb/dist/source/API/SBBreakpoint.cpp vendor/lldb/dist/source/API/SBCommandInterpreter.cpp vendor/lldb/dist/source/API/SBDebugger.cpp vendor/lldb/dist/source/API/SBFrame.cpp vendor/lldb/dist/source/API/SBModule.cpp vendor/lldb/dist/source/API/SBProcess.cpp vendor/lldb/dist/source/API/SBTarget.cpp vendor/lldb/dist/source/API/SBType.cpp vendor/lldb/dist/source/API/SBTypeCategory.cpp vendor/lldb/dist/source/API/SBTypeFormat.cpp vendor/lldb/dist/source/API/SBValue.cpp vendor/lldb/dist/source/Breakpoint/Breakpoint.cpp vendor/lldb/dist/source/Breakpoint/BreakpointLocation.cpp vendor/lldb/dist/source/Breakpoint/BreakpointLocationList.cpp vendor/lldb/dist/source/Breakpoint/BreakpointResolverName.cpp vendor/lldb/dist/source/Commands/CommandObjectBreakpointCommand.cpp vendor/lldb/dist/source/Commands/CommandObjectBreakpointCommand.h vendor/lldb/dist/source/Commands/CommandObjectCommands.cpp vendor/lldb/dist/source/Commands/CommandObjectDisassemble.cpp vendor/lldb/dist/source/Commands/CommandObjectExpression.cpp vendor/lldb/dist/source/Commands/CommandObjectExpression.h vendor/lldb/dist/source/Commands/CommandObjectMultiword.cpp vendor/lldb/dist/source/Commands/CommandObjectProcess.cpp vendor/lldb/dist/source/Commands/CommandObjectQuit.cpp vendor/lldb/dist/source/Commands/CommandObjectRegister.cpp vendor/lldb/dist/source/Commands/CommandObjectSource.cpp vendor/lldb/dist/source/Commands/CommandObjectTarget.cpp vendor/lldb/dist/source/Commands/CommandObjectType.cpp vendor/lldb/dist/source/Commands/CommandObjectWatchpointCommand.cpp vendor/lldb/dist/source/Commands/CommandObjectWatchpointCommand.h vendor/lldb/dist/source/Core/Address.cpp vendor/lldb/dist/source/Core/ArchSpec.cpp vendor/lldb/dist/source/Core/Broadcaster.cpp vendor/lldb/dist/source/Core/Communication.cpp vendor/lldb/dist/source/Core/ConnectionFileDescriptor.cpp vendor/lldb/dist/source/Core/DataExtractor.cpp vendor/lldb/dist/source/Core/Debugger.cpp vendor/lldb/dist/source/Core/Disassembler.cpp vendor/lldb/dist/source/Core/DynamicLoader.cpp vendor/lldb/dist/source/Core/Log.cpp vendor/lldb/dist/source/Core/Mangled.cpp vendor/lldb/dist/source/Core/Module.cpp vendor/lldb/dist/source/Core/Opcode.cpp vendor/lldb/dist/source/Core/Section.cpp vendor/lldb/dist/source/Core/SourceManager.cpp vendor/lldb/dist/source/Core/StreamAsynchronousIO.cpp vendor/lldb/dist/source/Core/StringList.cpp vendor/lldb/dist/source/Core/Value.cpp vendor/lldb/dist/source/Core/ValueObject.cpp vendor/lldb/dist/source/Core/ValueObjectChild.cpp vendor/lldb/dist/source/Core/ValueObjectVariable.cpp vendor/lldb/dist/source/DataFormatters/DataVisualization.cpp vendor/lldb/dist/source/DataFormatters/FormatManager.cpp vendor/lldb/dist/source/DataFormatters/LibCxx.cpp vendor/lldb/dist/source/DataFormatters/LibCxxUnorderedMap.cpp vendor/lldb/dist/source/DataFormatters/TypeCategory.cpp vendor/lldb/dist/source/DataFormatters/TypeFormat.cpp vendor/lldb/dist/source/DataFormatters/ValueObjectPrinter.cpp vendor/lldb/dist/source/Expression/ClangASTSource.cpp vendor/lldb/dist/source/Expression/ClangExpressionDeclMap.cpp vendor/lldb/dist/source/Expression/ClangExpressionParser.cpp vendor/lldb/dist/source/Expression/ClangUserExpression.cpp vendor/lldb/dist/source/Expression/DWARFExpression.cpp vendor/lldb/dist/source/Expression/IRDynamicChecks.cpp vendor/lldb/dist/source/Expression/IRExecutionUnit.cpp vendor/lldb/dist/source/Expression/IRForTarget.cpp vendor/lldb/dist/source/Expression/Materializer.cpp vendor/lldb/dist/source/Host/common/File.cpp vendor/lldb/dist/source/Host/common/Host.cpp vendor/lldb/dist/source/Host/common/OptionParser.cpp vendor/lldb/dist/source/Host/common/SocketAddress.cpp vendor/lldb/dist/source/Interpreter/CommandInterpreter.cpp vendor/lldb/dist/source/Interpreter/CommandObject.cpp vendor/lldb/dist/source/Interpreter/Options.cpp vendor/lldb/dist/source/Interpreter/PythonDataObjects.cpp vendor/lldb/dist/source/Interpreter/ScriptInterpreterNone.cpp vendor/lldb/dist/source/Interpreter/ScriptInterpreterPython.cpp vendor/lldb/dist/source/Interpreter/embedded_interpreter.py vendor/lldb/dist/source/Plugins/Disassembler/llvm/DisassemblerLLVMC.cpp vendor/lldb/dist/source/Plugins/DynamicLoader/POSIX-DYLD/DynamicLoaderPOSIXDYLD.cpp vendor/lldb/dist/source/Plugins/DynamicLoader/POSIX-DYLD/DynamicLoaderPOSIXDYLD.h vendor/lldb/dist/source/Plugins/DynamicLoader/Static/DynamicLoaderStatic.cpp vendor/lldb/dist/source/Plugins/Instruction/ARM/EmulateInstructionARM.cpp vendor/lldb/dist/source/Plugins/LanguageRuntime/CPlusPlus/ItaniumABI/ItaniumABILanguageRuntime.cpp vendor/lldb/dist/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp vendor/lldb/dist/source/Plugins/ObjectFile/ELF/ObjectFileELF.h vendor/lldb/dist/source/Plugins/OperatingSystem/Python/OperatingSystemPython.cpp vendor/lldb/dist/source/Plugins/OperatingSystem/Python/OperatingSystemPython.h vendor/lldb/dist/source/Plugins/Platform/FreeBSD/PlatformFreeBSD.cpp vendor/lldb/dist/source/Plugins/Platform/FreeBSD/PlatformFreeBSD.h vendor/lldb/dist/source/Plugins/Platform/POSIX/PlatformPOSIX.cpp vendor/lldb/dist/source/Plugins/Platform/POSIX/PlatformPOSIX.h vendor/lldb/dist/source/Plugins/Platform/gdb-server/PlatformRemoteGDBServer.cpp vendor/lldb/dist/source/Plugins/Platform/gdb-server/PlatformRemoteGDBServer.h vendor/lldb/dist/source/Plugins/Process/FreeBSD/ProcessFreeBSD.cpp vendor/lldb/dist/source/Plugins/Process/FreeBSD/ProcessFreeBSD.h vendor/lldb/dist/source/Plugins/Process/FreeBSD/ProcessMonitor.cpp vendor/lldb/dist/source/Plugins/Process/FreeBSD/ProcessMonitor.h vendor/lldb/dist/source/Plugins/Process/POSIX/POSIXThread.cpp vendor/lldb/dist/source/Plugins/Process/POSIX/ProcessPOSIX.cpp vendor/lldb/dist/source/Plugins/Process/POSIX/ProcessPOSIX.h vendor/lldb/dist/source/Plugins/Process/Utility/HistoryThread.cpp vendor/lldb/dist/source/Plugins/Process/Utility/HistoryThread.h vendor/lldb/dist/source/Plugins/Process/Utility/InferiorCallPOSIX.cpp vendor/lldb/dist/source/Plugins/Process/Utility/RegisterContextLLDB.cpp vendor/lldb/dist/source/Plugins/Process/Utility/RegisterContextLLDB.h vendor/lldb/dist/source/Plugins/Process/Utility/UnwindLLDB.cpp vendor/lldb/dist/source/Plugins/Process/Utility/UnwindLLDB.h vendor/lldb/dist/source/Plugins/Process/elf-core/ProcessElfCore.cpp vendor/lldb/dist/source/Plugins/Process/elf-core/RegisterContextPOSIXCore_x86_64.cpp vendor/lldb/dist/source/Plugins/Process/elf-core/ThreadElfCore.cpp vendor/lldb/dist/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.cpp vendor/lldb/dist/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.h vendor/lldb/dist/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp vendor/lldb/dist/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.h vendor/lldb/dist/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServer.cpp vendor/lldb/dist/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServer.h vendor/lldb/dist/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp vendor/lldb/dist/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp vendor/lldb/dist/source/Plugins/Process/gdb-remote/ProcessGDBRemote.h vendor/lldb/dist/source/Plugins/Process/gdb-remote/ThreadGDBRemote.cpp vendor/lldb/dist/source/Plugins/SymbolFile/DWARF/DWARFFormValue.h vendor/lldb/dist/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp vendor/lldb/dist/source/Plugins/SymbolVendor/ELF/SymbolVendorELF.cpp vendor/lldb/dist/source/Symbol/ClangASTContext.cpp vendor/lldb/dist/source/Symbol/ClangASTType.cpp vendor/lldb/dist/source/Symbol/FuncUnwinders.cpp vendor/lldb/dist/source/Symbol/Function.cpp vendor/lldb/dist/source/Symbol/Symbol.cpp vendor/lldb/dist/source/Symbol/Type.cpp vendor/lldb/dist/source/Symbol/Variable.cpp vendor/lldb/dist/source/Target/ExecutionContext.cpp vendor/lldb/dist/source/Target/LanguageRuntime.cpp vendor/lldb/dist/source/Target/Platform.cpp vendor/lldb/dist/source/Target/Process.cpp vendor/lldb/dist/source/Target/SectionLoadList.cpp vendor/lldb/dist/source/Target/StopInfo.cpp vendor/lldb/dist/source/Target/SystemRuntime.cpp vendor/lldb/dist/source/Target/Target.cpp vendor/lldb/dist/source/Target/Thread.cpp vendor/lldb/dist/source/Target/ThreadList.cpp vendor/lldb/dist/source/Target/ThreadPlanStepInRange.cpp vendor/lldb/dist/source/Target/ThreadPlanStepThrough.cpp vendor/lldb/dist/source/Target/ThreadPlanTracer.cpp vendor/lldb/dist/source/Target/UnwindAssembly.cpp vendor/lldb/dist/source/Utility/StringExtractorGDBRemote.cpp vendor/lldb/dist/source/Utility/StringExtractorGDBRemote.h vendor/lldb/dist/source/lldb-log.cpp vendor/lldb/dist/source/lldb.cpp vendor/lldb/dist/tools/driver/Driver.cpp vendor/lldb/dist/tools/driver/Driver.h vendor/lldb/dist/tools/driver/Platform.h vendor/lldb/dist/tools/lldb-platform/lldb-platform.cpp Modified: vendor/lldb/dist/include/lldb/API/LLDB.h ============================================================================== --- vendor/lldb/dist/include/lldb/API/LLDB.h Tue Feb 18 15:45:15 2014 (r262181) +++ vendor/lldb/dist/include/lldb/API/LLDB.h Tue Feb 18 16:23:10 2014 (r262182) @@ -33,13 +33,14 @@ #include "lldb/API/SBFrame.h" #include "lldb/API/SBFunction.h" #include "lldb/API/SBHostOS.h" -#include "lldb/API/SBInputReader.h" #include "lldb/API/SBInstruction.h" #include "lldb/API/SBInstructionList.h" #include "lldb/API/SBLineEntry.h" #include "lldb/API/SBListener.h" #include "lldb/API/SBModule.h" #include "lldb/API/SBProcess.h" +#include "lldb/API/SBQueue.h" +#include "lldb/API/SBQueueItem.h" #include "lldb/API/SBSourceManager.h" #include "lldb/API/SBStream.h" #include "lldb/API/SBStringList.h" Modified: vendor/lldb/dist/include/lldb/API/SBAddress.h ============================================================================== --- vendor/lldb/dist/include/lldb/API/SBAddress.h Tue Feb 18 15:45:15 2014 (r262181) +++ vendor/lldb/dist/include/lldb/API/SBAddress.h Tue Feb 18 16:23:10 2014 (r262182) @@ -118,6 +118,7 @@ protected: friend class SBTarget; friend class SBThread; friend class SBValue; + friend class SBQueueItem; lldb_private::Address * operator->(); Modified: vendor/lldb/dist/include/lldb/API/SBCommandInterpreter.h ============================================================================== --- vendor/lldb/dist/include/lldb/API/SBCommandInterpreter.h Tue Feb 18 15:45:15 2014 (r262181) +++ vendor/lldb/dist/include/lldb/API/SBCommandInterpreter.h Tue Feb 18 16:23:10 2014 (r262182) @@ -122,6 +122,36 @@ public: SBCommandInterpreter (lldb_private::CommandInterpreter *interpreter_ptr = NULL); // Access using SBDebugger::GetCommandInterpreter(); + //---------------------------------------------------------------------- + /// Return true if the command interpreter is the active IO handler. + /// + /// This indicates that any input coming into the debugger handles will + /// go to the command interpreter and will result in LLDB command line + /// commands being executed. + //---------------------------------------------------------------------- + bool + IsActive (); + + //---------------------------------------------------------------------- + /// Get the string that needs to be written to the debugger stdin file + /// handle when a control character is typed. + /// + /// Some GUI programs will intercept "control + char" sequences and want + /// to have them do what normally would happen when using a real + /// terminal, so this function allows GUI programs to emulate this + /// functionality. + /// + /// @param[in] ch + /// The character that was typed along with the control key + /// + /// @return + /// The string that should be written into the file handle that is + /// feeding the input stream for the debugger, or NULL if there is + /// no string for this control key. + //---------------------------------------------------------------------- + const char * + GetIOHandlerControlSequence(char ch); + protected: lldb_private::CommandInterpreter & Modified: vendor/lldb/dist/include/lldb/API/SBDebugger.h ============================================================================== --- vendor/lldb/dist/include/lldb/API/SBDebugger.h Tue Feb 18 15:45:15 2014 (r262181) +++ vendor/lldb/dist/include/lldb/API/SBDebugger.h Tue Feb 18 16:23:10 2014 (r262182) @@ -17,6 +17,16 @@ namespace lldb { + +class SBInputReader +{ +public: + SBInputReader(); + ~SBInputReader(); + SBError Initialize(lldb::SBDebugger&, unsigned long (*)(void*, lldb::SBInputReader*, lldb::InputReaderAction, char const*, unsigned long), void*, lldb::InputReaderGranularity, char const*, char const*, bool); + void SetIsDone(bool); + bool IsActive() const; +}; class SBDebugger { public: @@ -231,12 +241,6 @@ public: void PushInputReader (lldb::SBInputReader &reader); - void - NotifyTopInputReader (lldb::InputReaderAction notification); - - bool - InputReaderIsTopReader (const lldb::SBInputReader &reader); - const char * GetInstanceName (); @@ -313,6 +317,10 @@ public: GetSyntheticForType (SBTypeNameSpecifier); #endif + void + RunCommandInterpreter (bool auto_handle_events, + bool spawn_thread); + private: friend class SBCommandInterpreter; Modified: vendor/lldb/dist/include/lldb/API/SBDefines.h ============================================================================== --- vendor/lldb/dist/include/lldb/API/SBDefines.h Tue Feb 18 15:45:15 2014 (r262181) +++ vendor/lldb/dist/include/lldb/API/SBDefines.h Tue Feb 18 16:23:10 2014 (r262182) @@ -48,7 +48,6 @@ class SBFileSpecList; class SBFrame; class SBFunction; class SBHostOS; -class SBInputReader; class SBInstruction; class SBInstructionList; class SBLineEntry; Modified: vendor/lldb/dist/include/lldb/API/SBError.h ============================================================================== --- vendor/lldb/dist/include/lldb/API/SBError.h Tue Feb 18 15:45:15 2014 (r262181) +++ vendor/lldb/dist/include/lldb/API/SBError.h Tue Feb 18 16:23:10 2014 (r262182) @@ -71,7 +71,6 @@ protected: friend class SBDebugger; friend class SBCommunication; friend class SBHostOS; - friend class SBInputReader; friend class SBPlatform; friend class SBProcess; friend class SBThread; Modified: vendor/lldb/dist/include/lldb/API/SBModule.h ============================================================================== --- vendor/lldb/dist/include/lldb/API/SBModule.h Tue Feb 18 15:45:15 2014 (r262181) +++ vendor/lldb/dist/include/lldb/API/SBModule.h Tue Feb 18 16:23:10 2014 (r262182) @@ -235,6 +235,25 @@ public: lldb::SBTypeList FindTypes (const char* type); + //------------------------------------------------------------------ + /// Get a type using its type ID. + /// + /// Each symbol file reader will assign different user IDs to their + /// types, but it is sometimes useful when debugging type issues to + /// be able to grab a type using its type ID. + /// + /// For DWARF debug info, the type ID is the DIE offset. + /// + /// @param[in] uid + /// The type user ID. + /// + /// @return + /// An SBType for the given type ID, or an empty SBType if the + /// type was not found. + //------------------------------------------------------------------ + lldb::SBType + GetTypeByID (lldb::user_id_t uid); + lldb::SBType GetBasicType(lldb::BasicType type); Modified: vendor/lldb/dist/include/lldb/API/SBProcess.h ============================================================================== --- vendor/lldb/dist/include/lldb/API/SBProcess.h Tue Feb 18 15:45:15 2014 (r262181) +++ vendor/lldb/dist/include/lldb/API/SBProcess.h Tue Feb 18 16:23:10 2014 (r262182) @@ -13,6 +13,7 @@ #include "lldb/API/SBDefines.h" #include "lldb/API/SBError.h" #include "lldb/API/SBTarget.h" +#include "lldb/API/SBQueue.h" #include namespace lldb { @@ -142,6 +143,15 @@ public: SetSelectedThreadByIndexID (uint32_t index_id); //------------------------------------------------------------------ + // Queue related functions + //------------------------------------------------------------------ + uint32_t + GetNumQueues (); + + lldb::SBQueue + GetQueueAtIndex (size_t index); + + //------------------------------------------------------------------ // Stepping related functions //------------------------------------------------------------------ @@ -312,6 +322,7 @@ protected: friend class SBTarget; friend class SBThread; friend class SBValue; + friend class lldb_private::QueueImpl; lldb::ProcessSP GetSP() const; Added: vendor/lldb/dist/include/lldb/API/SBQueue.h ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ vendor/lldb/dist/include/lldb/API/SBQueue.h Tue Feb 18 16:23:10 2014 (r262182) @@ -0,0 +1,83 @@ +//===-- SBQueue.h -----------------------------------------------*- C++ -*-===// +// +// The LLVM Compiler Infrastructure +// +// This file is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +// +//===----------------------------------------------------------------------===// + +#ifndef LLDB_SBQueue_h_ +#define LLDB_SBQueue_h_ + +#include + +#include "lldb/lldb-forward.h" +#include "lldb/API/SBDefines.h" +#include "lldb/API/SBQueueItem.h" + +namespace lldb { + +class SBQueue +{ +public: + SBQueue (); + + SBQueue (const QueueSP& queue_sp); + + SBQueue (const SBQueue& rhs); + + const SBQueue & + operator= (const lldb::SBQueue& rhs); + + ~SBQueue(); + + bool + IsValid() const; + + void + Clear (); + + lldb::SBProcess + GetProcess (); + + lldb::queue_id_t + GetQueueID () const; + + const char * + GetName () const; + + uint32_t + GetIndexID () const; + + uint32_t + GetNumThreads (); + + lldb::SBThread + GetThreadAtIndex (uint32_t); + + uint32_t + GetNumPendingItems (); + + lldb::SBQueueItem + GetPendingItemAtIndex (uint32_t); + +protected: + friend class SBProcess; + + void + SetQueue (const lldb::QueueSP& queue_sp); + + void + FetchThreads (); + + void + FetchItems (); + +private: + std::shared_ptr m_opaque_sp; +}; + +} // namespace lldb + +#endif // LLDB_SBQueue_h_ Added: vendor/lldb/dist/include/lldb/API/SBQueueItem.h ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ vendor/lldb/dist/include/lldb/API/SBQueueItem.h Tue Feb 18 16:23:10 2014 (r262182) @@ -0,0 +1,58 @@ +//===-- SBQueueItem.h -------------------------------------------*- C++ -*-===// +// +// The LLVM Compiler Infrastructure +// +// This file is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +// +//===----------------------------------------------------------------------===// + +#ifndef LLDB_SBQueueItem_h_ +#define LLDB_SBQueueItem_h_ + +#include "lldb/API/SBDefines.h" +#include "lldb/API/SBAddress.h" +#include "lldb/API/SBThread.h" + +namespace lldb { + +class SBQueueItem +{ +public: + SBQueueItem (); + + SBQueueItem (const lldb::QueueItemSP& queue_item_sp); + + ~SBQueueItem(); + + bool + IsValid() const; + + void + Clear (); + + lldb::QueueItemKind + GetKind () const; + + void + SetKind (lldb::QueueItemKind kind); + + lldb::SBAddress + GetAddress () const; + + void + SetAddress (lldb::SBAddress addr); + + void + SetQueueItem (const lldb::QueueItemSP& queue_item_sp); + + SBThread + GetExtendedBacktraceThread (const char *type); + +private: + lldb::QueueItemSP m_queue_item_sp; +}; + +} // namespace lldb + +#endif // LLDB_SBQueueItem_h_ Modified: vendor/lldb/dist/include/lldb/API/SBTarget.h ============================================================================== --- vendor/lldb/dist/include/lldb/API/SBTarget.h Tue Feb 18 15:45:15 2014 (r262181) +++ vendor/lldb/dist/include/lldb/API/SBTarget.h Tue Feb 18 16:23:10 2014 (r262182) @@ -646,9 +646,47 @@ public: void Clear (); + //------------------------------------------------------------------ + /// Resolve a current load address into a section offset address. + /// + /// @param[in] vm_addr + /// A virtual address from the current process state that is to + /// be translated into a section offset address. + /// + /// @return + /// An SBAddress which will be valid if \a vm_addr was + /// successfully resolved into a section offset address, or an + /// invalid SBAddress if \a vm_addr doesn't resolve to a section + /// in a module. + //------------------------------------------------------------------ lldb::SBAddress ResolveLoadAddress (lldb::addr_t vm_addr); + //------------------------------------------------------------------ + /// Resolve a current load address into a section offset address + /// using the process stop ID to identify a time in the past. + /// + /// @param[in] stop_id + /// Each time a process stops, the process stop ID integer gets + /// incremented. These stop IDs are used to identify past times + /// and can be used in history objects as a cheap way to store + /// the time at which the sample was taken. Specifying + /// UINT32_MAX will always resolve the address using the + /// currently loaded sections. + /// + /// @param[in] vm_addr + /// A virtual address from the current process state that is to + /// be translated into a section offset address. + /// + /// @return + /// An SBAddress which will be valid if \a vm_addr was + /// successfully resolved into a section offset address, or an + /// invalid SBAddress if \a vm_addr doesn't resolve to a section + /// in a module. + //------------------------------------------------------------------ + lldb::SBAddress + ResolvePastLoadAddress (uint32_t stop_id, lldb::addr_t vm_addr); + SBSymbolContext ResolveSymbolContextForAddress (const SBAddress& addr, uint32_t resolve_scope); Modified: vendor/lldb/dist/include/lldb/API/SBThread.h ============================================================================== --- vendor/lldb/dist/include/lldb/API/SBThread.h Tue Feb 18 15:45:15 2014 (r262181) +++ vendor/lldb/dist/include/lldb/API/SBThread.h Tue Feb 18 16:23:10 2014 (r262182) @@ -214,6 +214,8 @@ protected: friend class SBProcess; friend class SBDebugger; friend class SBValue; + friend class lldb_private::QueueImpl; + friend class SBQueueItem; void SetThread (const lldb::ThreadSP& lldb_object_sp); Modified: vendor/lldb/dist/include/lldb/API/SBType.h ============================================================================== --- vendor/lldb/dist/include/lldb/API/SBType.h Tue Feb 18 15:45:15 2014 (r262181) +++ vendor/lldb/dist/include/lldb/API/SBType.h Tue Feb 18 16:23:10 2014 (r262182) @@ -106,6 +106,9 @@ public: GetReferenceType(); lldb::SBType + GetTypedefedType(); + + lldb::SBType GetDereferencedType(); lldb::SBType Modified: vendor/lldb/dist/include/lldb/API/SBTypeFormat.h ============================================================================== --- vendor/lldb/dist/include/lldb/API/SBTypeFormat.h Tue Feb 18 15:45:15 2014 (r262181) +++ vendor/lldb/dist/include/lldb/API/SBTypeFormat.h Tue Feb 18 16:23:10 2014 (r262182) @@ -22,6 +22,9 @@ public: SBTypeFormat (lldb::Format format, uint32_t options = 0); // see lldb::eTypeOption values + + SBTypeFormat (const char* type, + uint32_t options = 0); // see lldb::eTypeOption values SBTypeFormat (const lldb::SBTypeFormat &rhs); @@ -33,6 +36,9 @@ public: lldb::Format GetFormat (); + const char* + GetTypeName (); + uint32_t GetOptions(); @@ -40,6 +46,9 @@ public: SetFormat (lldb::Format); void + SetTypeName (const char*); + + void SetOptions (uint32_t); bool @@ -73,8 +82,15 @@ protected: SBTypeFormat (const lldb::TypeFormatImplSP &); + enum class Type + { + eTypeKeepSame, + eTypeFormat, + eTypeEnum + }; + bool - CopyOnWrite_Impl(); + CopyOnWrite_Impl(Type); }; Modified: vendor/lldb/dist/include/lldb/Breakpoint/Breakpoint.h ============================================================================== --- vendor/lldb/dist/include/lldb/Breakpoint/Breakpoint.h Tue Feb 18 15:45:15 2014 (r262181) +++ vendor/lldb/dist/include/lldb/Breakpoint/Breakpoint.h Tue Feb 18 16:23:10 2014 (r262182) @@ -612,12 +612,30 @@ protected: /// Only the Target can make a breakpoint, and it owns the breakpoint lifespans. /// The constructor takes a filter and a resolver. Up in Target there are convenience /// variants that make breakpoints for some common cases. + /// + /// @param[in] target + /// The target in which the breakpoint will be set. + /// + /// @param[in] filter_sp + /// Shared pointer to the search filter that restricts the search domain of the breakpoint. + /// + /// @param[in] resolver_sp + /// Shared pointer to the resolver object that will determine breakpoint matches. + /// + /// @param hardware + /// If true, request a hardware breakpoint to be used to implement the breakpoint locations. + /// + /// @param resolve_indirect_symbols + /// If true, and the address of a given breakpoint location in this breakpoint is set on an + /// indirect symbol (i.e. Symbol::IsIndirect returns true) then the actual breakpoint site will + /// be set on the target of the indirect symbol. //------------------------------------------------------------------ // This is the generic constructor Breakpoint(Target &target, lldb::SearchFilterSP &filter_sp, lldb::BreakpointResolverSP &resolver_sp, - bool hardware); + bool hardware, + bool resolve_indirect_symbols = true); friend class BreakpointLocation; // To call the following two when determining whether to stop. @@ -643,6 +661,7 @@ private: BreakpointOptions m_options; // Settable breakpoint options BreakpointLocationList m_locations; // The list of locations currently found for this breakpoint. std::string m_kind_description; + bool m_resolve_indirect_symbols; void SendBreakpointChangedEvent (lldb::BreakpointEventType eventKind); Modified: vendor/lldb/dist/include/lldb/Breakpoint/BreakpointLocation.h ============================================================================== --- vendor/lldb/dist/include/lldb/Breakpoint/BreakpointLocation.h Tue Feb 18 15:45:15 2014 (r262181) +++ vendor/lldb/dist/include/lldb/Breakpoint/BreakpointLocation.h Tue Feb 18 16:23:10 2014 (r262182) @@ -321,7 +321,59 @@ public: //------------------------------------------------------------------ bool InvokeCallback (StoppointCallbackContext *context); + + //------------------------------------------------------------------ + /// Returns whether we should resolve Indirect functions in setting the breakpoint site + /// for this location. + /// + /// @return + /// \b true if the breakpoint SITE for this location should be set on the + /// resolved location for Indirect functions. + //------------------------------------------------------------------ + bool + ShouldResolveIndirectFunctions () + { + return m_should_resolve_indirect_functions; + } + //------------------------------------------------------------------ + /// Returns whether the address set in the breakpoint site for this location was found by resolving + /// an indirect symbol. + /// + /// @return + /// \b true or \b false as given in the description above. + //------------------------------------------------------------------ + bool + IsIndirect () + { + return m_is_indirect; + } + + void + SetIsIndirect (bool is_indirect) + { + m_is_indirect = is_indirect; + } + + //------------------------------------------------------------------ + /// Returns whether the address set in the breakpoint location was re-routed to the target of a + /// re-exported symbol. + /// + /// @return + /// \b true or \b false as given in the description above. + //------------------------------------------------------------------ + bool + IsReExported () + { + return m_is_reexported; + } + + void + SetIsReExported (bool is_reexported) + { + m_is_reexported = is_reexported; + } + protected: friend class BreakpointLocationList; friend class Process; @@ -375,12 +427,16 @@ private: Breakpoint &owner, const Address &addr, lldb::tid_t tid, - bool hardware); - + bool hardware, + bool check_for_resolver = true); + //------------------------------------------------------------------ // Data members: //------------------------------------------------------------------ bool m_being_created; + bool m_should_resolve_indirect_functions; + bool m_is_reexported; + bool m_is_indirect; Address m_address; ///< The address defining this location. Breakpoint &m_owner; ///< The breakpoint that produced this object. std::unique_ptr m_options_ap; ///< Breakpoint options pointer, NULL if we're using our breakpoint's options. @@ -390,6 +446,12 @@ private: size_t m_condition_hash; ///< For testing whether the condition source code changed. void + SetShouldResolveIndirectFunctions (bool do_resolve) + { + m_should_resolve_indirect_functions = do_resolve; + } + + void SendBreakpointLocationChangedEvent (lldb::BreakpointEventType eventKind); DISALLOW_COPY_AND_ASSIGN (BreakpointLocation); Modified: vendor/lldb/dist/include/lldb/Breakpoint/BreakpointLocationList.h ============================================================================== --- vendor/lldb/dist/include/lldb/Breakpoint/BreakpointLocationList.h Tue Feb 18 15:45:15 2014 (r262181) +++ vendor/lldb/dist/include/lldb/Breakpoint/BreakpointLocationList.h Tue Feb 18 16:23:10 2014 (r262182) @@ -236,7 +236,7 @@ protected: /// Returns breakpoint location id. //------------------------------------------------------------------ lldb::BreakpointLocationSP - Create (const Address &addr); + Create (const Address &addr, bool resolve_indirect_symbols); void StartRecordingNewLocations(BreakpointLocationCollection &new_locations); @@ -246,6 +246,7 @@ protected: lldb::BreakpointLocationSP AddLocation (const Address &addr, + bool resolve_indirect_symbols, bool *new_location = NULL); bool Modified: vendor/lldb/dist/include/lldb/Core/ArchSpec.h ============================================================================== --- vendor/lldb/dist/include/lldb/Core/ArchSpec.h Tue Feb 18 15:45:15 2014 (r262181) +++ vendor/lldb/dist/include/lldb/Core/ArchSpec.h Tue Feb 18 16:23:10 2014 (r262182) @@ -13,6 +13,7 @@ #if defined(__cplusplus) #include "lldb/lldb-private.h" +#include "lldb/Core/ConstString.h" #include "llvm/ADT/StringRef.h" #include "llvm/ADT/Triple.h" @@ -90,6 +91,7 @@ public: eCore_x86_32_i486sx, eCore_x86_64_x86_64, + eCore_x86_64_x86_64h, // Haswell enabled x86_64 eCore_uknownMach32, eCore_uknownMach64, kNumCores, @@ -203,6 +205,27 @@ public: GetMachine () const; //------------------------------------------------------------------ + /// Returns the distribution id of the architecture. + /// + /// This will be something like "ubuntu", "fedora", etc. on Linux. + /// + /// @return A ConstString ref containing the distribution id, + /// potentially empty. + //------------------------------------------------------------------ + const ConstString& + GetDistributionId () const; + + //------------------------------------------------------------------ + /// Set the distribution id of the architecture. + /// + /// This will be something like "ubuntu", "fedora", etc. on Linux. + /// This should be the same value returned by + /// Host::GetDistributionId (). + ///------------------------------------------------------------------ + void + SetDistributionId (const char* distribution_id); + + //------------------------------------------------------------------ /// Tests if this ArchSpec is valid. /// /// @return True if the current architecture is valid, false @@ -400,6 +423,8 @@ protected: Core m_core; lldb::ByteOrder m_byte_order; + ConstString m_distribution_id; + // Called when m_def or m_entry are changed. Fills in all remaining // members with default values. void Modified: vendor/lldb/dist/include/lldb/Core/Communication.h ============================================================================== --- vendor/lldb/dist/include/lldb/Core/Communication.h Tue Feb 18 15:45:15 2014 (r262181) +++ vendor/lldb/dist/include/lldb/Core/Communication.h Tue Feb 18 16:23:10 2014 (r262182) @@ -286,6 +286,8 @@ public: virtual bool StopReadThread (Error *error_ptr = NULL); + virtual bool + JoinReadThread (Error *error_ptr = NULL); //------------------------------------------------------------------ /// Checks if there is a currently running read thread. /// Modified: vendor/lldb/dist/include/lldb/Core/ConnectionFileDescriptor.h ============================================================================== --- vendor/lldb/dist/include/lldb/Core/ConnectionFileDescriptor.h Tue Feb 18 15:45:15 2014 (r262181) +++ vendor/lldb/dist/include/lldb/Core/ConnectionFileDescriptor.h Tue Feb 18 16:23:10 2014 (r262182) @@ -11,9 +11,7 @@ #define liblldb_ConnectionFileDescriptor_h_ // C Includes -#ifdef _WIN32 -typedef unsigned short in_port_t; -#else +#ifndef _WIN32 #include #include #include @@ -68,14 +66,17 @@ public: // If the read file descriptor is a socket, then return // the port number that is being used by the socket. - in_port_t + uint16_t GetReadPort () const; // If the write file descriptor is a socket, then return // the port number that is being used by the socket. - in_port_t + uint16_t GetWritePort () const; + uint16_t + GetBoundPort (uint32_t timeout_sec); + protected: typedef enum @@ -95,7 +96,7 @@ protected: BytesAvailable (uint32_t timeout_usec, Error *error_ptr); lldb::ConnectionStatus - SocketListen (uint16_t listen_port_num, Error *error_ptr); + SocketListen (const char *host_and_port, Error *error_ptr); lldb::ConnectionStatus ConnectTCP (const char *host_and_port, Error *error_ptr); @@ -117,15 +118,16 @@ protected: FDType m_fd_send_type; FDType m_fd_recv_type; std::unique_ptr m_udp_send_sockaddr; - bool m_should_close_fd; // True if this class should close the file descriptor when it goes away. uint32_t m_socket_timeout_usec; int m_pipe_read; // A pipe that we select on the reading end of along with int m_pipe_write; // m_fd_recv so we can force ourselves out of the select. - Mutex m_mutex; + Mutex m_mutex; + Predicate m_port_predicate; // Used when binding to port zero to wait for the thread that creates the socket, binds and listens to resolve the port number + bool m_should_close_fd; // True if this class should close the file descriptor when it goes away. bool m_shutting_down; // This marks that we are shutting down so if we get woken up from BytesAvailable // to disconnect, we won't try to read again. - static in_port_t + static uint16_t GetSocketPort (int fd); static int Modified: vendor/lldb/dist/include/lldb/Core/Debugger.h ============================================================================== --- vendor/lldb/dist/include/lldb/Core/Debugger.h Tue Feb 18 15:45:15 2014 (r262181) +++ vendor/lldb/dist/include/lldb/Core/Debugger.h Tue Feb 18 16:23:10 2014 (r262182) @@ -19,9 +19,8 @@ #include "lldb/lldb-public.h" #include "lldb/Core/Broadcaster.h" #include "lldb/Core/Communication.h" -#include "lldb/Core/InputReaderStack.h" +#include "lldb/Core/IOHandler.h" #include "lldb/Core/Listener.h" -#include "lldb/Core/StreamFile.h" #include "lldb/Core/SourceManager.h" #include "lldb/Core/UserID.h" #include "lldb/Core/UserSettingsController.h" @@ -91,23 +90,25 @@ public: void SetAsyncExecution (bool async); - File & + lldb::StreamFileSP GetInputFile () { - return m_input_file.GetFile(); + return m_input_file_sp; } - File & + lldb::StreamFileSP GetOutputFile () { - return m_output_file.GetFile(); + return m_output_file_sp; } - File & + lldb::StreamFileSP GetErrorFile () { - return m_error_file.GetFile(); + return m_error_file_sp; } + + void SetInputFileHandle (FILE *fh, bool tranfer_ownership); @@ -124,18 +125,6 @@ public: void RestoreInputTerminalState(); - Stream& - GetOutputStream () - { - return m_output_file; - } - - Stream& - GetErrorStream () - { - return m_error_file; - } - lldb::StreamSP GetAsyncOutputStream (); @@ -200,24 +189,38 @@ public: void DispatchInputEndOfFile (); + //------------------------------------------------------------------ + // If any of the streams are not set, set them to the in/out/err + // stream of the top most input reader to ensure they at least have + // something + //------------------------------------------------------------------ void - DispatchInput (const char *bytes, size_t bytes_len); + AdoptTopIOHandlerFilesIfInvalid (lldb::StreamFileSP &in, + lldb::StreamFileSP &out, + lldb::StreamFileSP &err); void - WriteToDefaultReader (const char *bytes, size_t bytes_len); + PushIOHandler (const lldb::IOHandlerSP& reader_sp); + bool + PopIOHandler (const lldb::IOHandlerSP& reader_sp); + + // Synchronously run an input reader until it is done void - PushInputReader (const lldb::InputReaderSP& reader_sp); + RunIOHandler (const lldb::IOHandlerSP& reader_sp); + + bool + IsTopIOHandler (const lldb::IOHandlerSP& reader_sp); + + ConstString + GetTopIOHandlerControlSequence(char ch); bool - PopInputReader (const lldb::InputReaderSP& reader_sp); + HideTopIOHandler(); void - NotifyTopInputReader (lldb::InputReaderAction notification); + RefreshTopIOHandler(); - bool - InputReaderIsTopReader (const lldb::InputReaderSP& reader_sp); - static lldb::DebuggerSP FindDebuggerWithID (lldb::user_id_t id); @@ -240,7 +243,7 @@ public: void - CleanUpInputReaders (); + ClearIOHandlers (); static int TestDebuggerRefCount (); @@ -338,29 +341,65 @@ public: bool LoadPlugin (const FileSpec& spec, Error& error); + void + ExecuteIOHanders(); + + bool + IsForwardingEvents (); + + void + EnableForwardEvents (const lldb::ListenerSP &listener_sp); + + void + CancelForwardEvents (const lldb::ListenerSP &listener_sp); protected: - static void - DispatchInputCallback (void *baton, const void *bytes, size_t bytes_len); + friend class CommandInterpreter; + + bool + StartEventHandlerThread(); - lldb::InputReaderSP - GetCurrentInputReader (); - void - ActivateInputReader (const lldb::InputReaderSP &reader_sp); + StopEventHandlerThread(); + + static lldb::thread_result_t + EventHandlerThread (lldb::thread_arg_t arg); bool - CheckIfTopInputReaderIsDone (); + StartIOHandlerThread(); + + void + StopIOHandlerThread(); + static lldb::thread_result_t + IOHandlerThread (lldb::thread_arg_t arg); + + void + DefaultEventHandler(); + + void + HandleBreakpointEvent (const lldb::EventSP &event_sp); + + void + HandleProcessEvent (const lldb::EventSP &event_sp); + + void + HandleThreadEvent (const lldb::EventSP &event_sp); + + size_t + GetProcessSTDOUT (Process *process, Stream *stream); + + size_t + GetProcessSTDERR (Process *process, Stream *stream); + SourceManager::SourceFileCache & GetSourceFileCache () { return m_source_file_cache; } - Communication m_input_comm; - StreamFile m_input_file; - StreamFile m_output_file; - StreamFile m_error_file; + lldb::StreamFileSP m_input_file_sp; + lldb::StreamFileSP m_output_file_sp; + lldb::StreamFileSP m_error_file_sp; TerminalState m_terminal_state; TargetList m_target_list; PlatformList m_platform_list; @@ -370,8 +409,7 @@ protected: // source file cache. std::unique_ptr m_command_interpreter_ap; - InputReaderStack m_input_reader_stack; - std::string m_input_reader_data; + IOHandlerStack m_input_reader_stack; typedef std::map LogStreamMap; LogStreamMap m_log_streams; lldb::StreamSP m_log_callback_stream_sp; @@ -379,7 +417,10 @@ protected: static LoadPluginCallbackType g_load_plugin_callback; typedef std::vector LoadedPluginsList; LoadedPluginsList m_loaded_plugins; - + lldb::thread_t m_event_handler_thread; + lldb::thread_t m_io_handler_thread; + lldb::ListenerSP m_forward_listener_sp; + bool m_event_handler_thread_alive; void InstanceInitialize (); Modified: vendor/lldb/dist/include/lldb/Core/Disassembler.h ============================================================================== --- vendor/lldb/dist/include/lldb/Core/Disassembler.h Tue Feb 18 15:45:15 2014 (r262181) +++ vendor/lldb/dist/include/lldb/Core/Disassembler.h Tue Feb 18 16:23:10 2014 (r262182) @@ -175,6 +175,9 @@ public: uint32_t GetIndexOfInstructionAtLoadAddress (lldb::addr_t load_addr, Target &target); + uint32_t + GetIndexOfInstructionAtAddress (const Address &addr); + void Clear(); Added: vendor/lldb/dist/include/lldb/Core/IOHandler.h ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ vendor/lldb/dist/include/lldb/Core/IOHandler.h Tue Feb 18 16:23:10 2014 (r262182) @@ -0,0 +1,646 @@ +//===-- IOHandler.h ---------------------------------------------*- C++ -*-===// +// +// The LLVM Compiler Infrastructure +// +// This file is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +// +//===----------------------------------------------------------------------===// + +#ifndef liblldb_IOHandler_h_ +#define liblldb_IOHandler_h_ + +#include + +#include + +#include "lldb/lldb-public.h" +#include "lldb/lldb-enumerations.h" +#include "lldb/Core/ConstString.h" +#include "lldb/Core/Error.h" +#include "lldb/Core/Flags.h" +#include "lldb/Core/StringList.h" *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-vendor@FreeBSD.ORG Tue Feb 18 16:26:19 2014 Return-Path: Delivered-To: svn-src-vendor@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id F1E5CB65; Tue, 18 Feb 2014 16:26:18 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id C125F181D; Tue, 18 Feb 2014 16:26:18 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s1IGQIbN034897; Tue, 18 Feb 2014 16:26:18 GMT (envelope-from emaste@svn.freebsd.org) Received: (from emaste@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s1IGQIWH034896; Tue, 18 Feb 2014 16:26:18 GMT (envelope-from emaste@svn.freebsd.org) Message-Id: <201402181626.s1IGQIWH034896@svn.freebsd.org> From: Ed Maste Date: Tue, 18 Feb 2014 16:26:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org Subject: svn commit: r262183 - vendor/lldb/lldb-r201577 X-SVN-Group: vendor MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-vendor@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: SVN commit messages for the vendor work area tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Feb 2014 16:26:19 -0000 Author: emaste Date: Tue Feb 18 16:26:18 2014 New Revision: 262183 URL: http://svnweb.freebsd.org/changeset/base/262183 Log: Tag lldb r201577 Added: vendor/lldb/lldb-r201577/ - copied from r262182, vendor/lldb/dist/ From owner-svn-src-vendor@FreeBSD.ORG Thu Feb 20 19:26:16 2014 Return-Path: Delivered-To: svn-src-vendor@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 0BA0B77; Thu, 20 Feb 2014 19:26:16 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id E691B15D0; Thu, 20 Feb 2014 19:26:15 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s1KJQFk2013322; Thu, 20 Feb 2014 19:26:15 GMT (envelope-from peter@svn.freebsd.org) Received: (from peter@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s1KJQBjr013292; Thu, 20 Feb 2014 19:26:11 GMT (envelope-from peter@svn.freebsd.org) Message-Id: <201402201926.s1KJQBjr013292@svn.freebsd.org> From: Peter Wemm Date: Thu, 20 Feb 2014 19:26:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org Subject: svn commit: r262248 - in vendor/subversion/dist: . subversion/include subversion/include/private subversion/libsvn_client subversion/libsvn_fs_fs subversion/libsvn_ra_serf subversion/libsvn_repos s... X-SVN-Group: vendor MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-vendor@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: SVN commit messages for the vendor work area tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 20 Feb 2014 19:26:16 -0000 Author: peter Date: Thu Feb 20 19:26:10 2014 New Revision: 262248 URL: http://svnweb.freebsd.org/changeset/base/262248 Log: Vendor import svn-1.8.8 Modified: vendor/subversion/dist/CHANGES vendor/subversion/dist/Makefile.in vendor/subversion/dist/NOTICE vendor/subversion/dist/build-outputs.mk vendor/subversion/dist/build.conf vendor/subversion/dist/configure vendor/subversion/dist/configure.ac vendor/subversion/dist/subversion/include/private/svn_auth_private.h vendor/subversion/dist/subversion/include/private/svn_diff_tree.h vendor/subversion/dist/subversion/include/private/svn_mutex.h vendor/subversion/dist/subversion/include/svn_auth.h vendor/subversion/dist/subversion/include/svn_client.h vendor/subversion/dist/subversion/include/svn_config.h vendor/subversion/dist/subversion/include/svn_diff.h vendor/subversion/dist/subversion/include/svn_dirent_uri.h vendor/subversion/dist/subversion/include/svn_io.h vendor/subversion/dist/subversion/include/svn_repos.h vendor/subversion/dist/subversion/include/svn_version.h vendor/subversion/dist/subversion/include/svn_wc.h vendor/subversion/dist/subversion/libsvn_client/copy.c vendor/subversion/dist/subversion/libsvn_client/log.c vendor/subversion/dist/subversion/libsvn_client/prop_commands.c vendor/subversion/dist/subversion/libsvn_client/update.c vendor/subversion/dist/subversion/libsvn_client/util.c vendor/subversion/dist/subversion/libsvn_fs_fs/fs_fs.c vendor/subversion/dist/subversion/libsvn_fs_fs/rep-cache-db.h vendor/subversion/dist/subversion/libsvn_fs_fs/rep-cache.c vendor/subversion/dist/subversion/libsvn_ra_serf/commit.c vendor/subversion/dist/subversion/libsvn_ra_serf/util.c vendor/subversion/dist/subversion/libsvn_repos/commit.c vendor/subversion/dist/subversion/libsvn_repos/reporter.c vendor/subversion/dist/subversion/libsvn_subr/auth.c vendor/subversion/dist/subversion/libsvn_subr/cache-membuffer.c vendor/subversion/dist/subversion/libsvn_subr/cmdline.c vendor/subversion/dist/subversion/libsvn_subr/internal_statements.h vendor/subversion/dist/subversion/libsvn_subr/io.c vendor/subversion/dist/subversion/libsvn_subr/sqlite.c vendor/subversion/dist/subversion/libsvn_subr/sqlite3wrapper.c vendor/subversion/dist/subversion/libsvn_subr/subst.c vendor/subversion/dist/subversion/libsvn_subr/sysinfo.c vendor/subversion/dist/subversion/libsvn_subr/win32_crypto.c vendor/subversion/dist/subversion/libsvn_wc/conflicts.h vendor/subversion/dist/subversion/libsvn_wc/diff_local.c vendor/subversion/dist/subversion/libsvn_wc/upgrade.c vendor/subversion/dist/subversion/libsvn_wc/wc-checks.h vendor/subversion/dist/subversion/libsvn_wc/wc-metadata.h vendor/subversion/dist/subversion/libsvn_wc/wc-metadata.sql vendor/subversion/dist/subversion/libsvn_wc/wc-queries.h vendor/subversion/dist/subversion/libsvn_wc/wc-queries.sql vendor/subversion/dist/subversion/libsvn_wc/wc.h vendor/subversion/dist/subversion/libsvn_wc/wc_db.c vendor/subversion/dist/subversion/libsvn_wc/wc_db.h vendor/subversion/dist/subversion/libsvn_wc/wc_db_util.c vendor/subversion/dist/subversion/svn/conflict-callbacks.c vendor/subversion/dist/subversion/svn/status-cmd.c vendor/subversion/dist/subversion/svn/svn.c vendor/subversion/dist/subversion/svnserve/svnserve.c Modified: vendor/subversion/dist/CHANGES ============================================================================== --- vendor/subversion/dist/CHANGES Thu Feb 20 17:23:08 2014 (r262247) +++ vendor/subversion/dist/CHANGES Thu Feb 20 19:26:10 2014 (r262248) @@ -1,3 +1,70 @@ +Version 1.8.8 +(19 Feb 2014, from /branches/1.8.x) +http://svn.apache.org/repos/asf/subversion/tags/1.8.8 + + User-visible changes: + - Client-side bugfixes: + * use CryptoAPI to validate intermediary certificates on Windows (r1564623) + * fix automatic relocate for wcs not at repository root (r1541638 et al) + * diff: fix when target is a drive root on Windows (r1541635) + * wc: improve performance when used with SQLite 3.8 (r1542765) + * copy: fix some scenarios that broke the working copy (r1560690) + * move: fix errors when moving files between an external and the parent + working copy (r1551524, r1551579) + * log: resolve performance regression in certain scenarios (r1553101 et al) + * merge: decrease work to detect differences between 3 files (r1548486) + * checkout: don't require flush support for symlinks on Windows (r1547774) + * commit: don't change file permissions inappropriately (issue #4440) + * commit: fix assertion due to invalid pool lifetime (r1553376 et al) + * version: don't cut off the distribution version on Linux (r1544878 et al) + * flush stdout before exiting to avoid information being lost (r1499470) + * status: fix missing sentinel value on warning codes (r1543145) + * update/switch: improve some WC db queries that may return incorrect + results depending on how SQLite is built (r1567109) + + - Server-side bugfixes: + * reduce memory usage during checkout and export (r1564215) + * fsfs: create rep-cache.db with proper permissions (issue #3437) + * mod_dav_svn: prevent crashes with SVNListParentPath on (CVE-2014-0032) + * mod_dav_svn: fix SVNAllowBulkUpdates directive merging (r1548105) + * mod_dav_svn: include requested property changes in reports (r1557522) + * svnserve: correct default cache size in help text (r1563110) + * svnadmin dump: reduce size of dump files with '--deltas' (r1554978) + * resolve integer underflow that resulted in infinite loops (r1567985) + + Developer-visible changes: + - General: + * fix ocassional failure of check_tests.py 12 (r1496127 et al) + * fix failure with SQLite 3.8.1-3.8.3 when built with + SQLITE_ENABLE_STAT3/4 due to bug in SQLite (r1567286, r1567392) + * specify SQLite defaults that can be changed when SQLite is built + to avoid unexpected behavior with Subversion (r1567064) + + - API changes: + * numerous documentation fixes + * svn_client_commit_item3_dup() fix pool lifetime issues (r1550803) + * ra_serf: properly ask multiple certificate validation providers for + acceptance of certificate failures (r1535532) + * release internal fs objects when closing commit editor (r1555499) + * svn_client_proplist4() don't call the callback multiple times for + the same path in order to deliver inherited properties (r1549858 et al) + + - Bindings: + * javahl: make test suite run without installing on OS X (r1535115) + * swig: fix building out of tarball on OS X (r1555654) + * swig-pl: fix with --enable-sqlite-compatibility-version (r1559009) + * swig: fix building bindings on OS X when APR has the -no-cpp-precomp + flag in the apr-config --cppflags output. (r1535610) + * swig: fix building from tarball with an out-of-tree build (r1543187) + + +Version 1.8.7 +(Not released, see changes for 1.8.8.) + +Version 1.8.6 +(Not released, see changes for 1.8.8.) + + Version 1.8.5 (25 November 2013, from /branches/1.8.x) http://svn.apache.org/repos/asf/subversion/tags/1.8.5 @@ -19,7 +86,7 @@ http://svn.apache.org/repos/asf/subversi Developer-visible changes: - General: * fix compilation with '--enable-optimize' with clang (r1534860) - * fix copmpilation with debug build of BDB on Windows (r1501656, r1501702) + * fix compilation with debug build of BDB on Windows (r1501656, r1501702) * fix '--with-openssl' option when building on Windows (r1535139) * add test to fail when built against broken ZLib (r1537193 et al) @@ -305,7 +372,7 @@ http://svn.apache.org/repos/asf/subversi * decreased default http timeout for ra_serf (issue #3968) * prevent ra_serf from corrupting the working copy (issue #3993) * ra_serf transmits property changes inline to reduce requests (r1378927) - * allow client to avoid SSL certificate prompts (issue #2410) + * by default avoid SSL certificate prompts in client (issue #2410) * improve interactive resolution of property conflicts (r1387678 et al) * make ra_serf raise an error upon delta-base mismatch (issue #4235) * tune ra_svn transmit buffer handling (r1391788) @@ -515,7 +582,7 @@ http://svn.apache.org/repos/asf/subversi * configure now script auto-detects GNOME keyring (r1387230) * allow configure to detect BDB on Debian-based Linux distros (r1390633) * auto-detect serf via pkg-config (r1391662) - * improve queries for compatability with SQLite 3.7.16 (r1455239) + * improve queries for compatibility with SQLite 3.7.16 (r1455239) * remove support for in-tree apr, apr-util and apr-memcache (r1456924) * FSFS caching supports prefixes now (r1462436) * maintainer mode now prints symbolic error codes (r1465157) @@ -553,6 +620,25 @@ http://svn.apache.org/repos/asf/subversi * fix some reference counting bugs in swig-py bindings (r1464899, r1466524) +Version 1.7.15 +(12 Feb 2014, from /branches/1.7.x) +http://svn.apache.org/repos/asf/subversion/tags/1.7.15 + + User-visible changes: + - Client-side bugfixes: + * copy: fix some scenarios that broke the working copy (r1560690) + * diff: fix regressions due to fixes in 1.7.14 (issue #4460) + + - Server-side bugfixes: + * mod_dav_svn: prevent crashes with SVNListParentPath on (CVE-2014-0032) + * reduce memory usage during checkout and export (r1564215) + + Developer-visible changes: + - General: + * fix failure in checkout_tests.py + * support compiling against Cyrus sasl 2.1.25 (r1404912, r1413402) + + Version 1.7.14 (25 Nov 2013, from /branches/1.7.x) http://svn.apache.org/repos/asf/subversion/tags/1.7.14 @@ -1326,7 +1412,7 @@ http://svn.apache.org/repos/asf/subversi http://subversion.apache.org/security/CVE-2011-1752-advisory.txt * fixed: write-through proxy could direcly commit to slave (r917523) * detect a particular corruption condition in FSFS (r1100213) - * improve error message when clients refer to unkown revisions (r939000) + * improve error message when clients refer to unknown revisions (r939000) * bugfixes and optimizations to the DAV mirroring code (r878607) * fixed: locked and deleted file causes tree conflict (issue #3525) * fixed: update touches locked file with svn:keywords property (issue #3471) @@ -1696,7 +1782,7 @@ http://svn.apache.org/repos/asf/subversi * improve performance of 'svn update' on large files (r36389, et. al.) * fixed: error leak and potential crash (r36860) * fixed: parent directory handling on Windows (r36049, -50, -51, -131) - * fixed: unintialized memory errors (r36252, -3) + * fixed: uninitialized memory errors (r36252, -3) * fixed: potential working copy corruption (r36714) * fixed: working copy upgrade error (r36302) * fixed: pointer dereference error (r36783) Modified: vendor/subversion/dist/Makefile.in ============================================================================== --- vendor/subversion/dist/Makefile.in Thu Feb 20 17:23:08 2014 (r262247) +++ vendor/subversion/dist/Makefile.in Thu Feb 20 19:26:10 2014 (r262248) @@ -177,6 +177,7 @@ CXXMAINTAINERFLAGS = @CXXMAINTAINERFLAGS CPPFLAGS = @CPPFLAGS@ $(EXTRA_CPPFLAGS) LDFLAGS = @LDFLAGS@ $(EXTRA_LDFLAGS) SWIG_LDFLAGS = @SWIG_LDFLAGS@ $(EXTRA_SWIG_LDFLAGS) +SWIG_CPPFLAGS = @SWIG_CPPFLAGS@ $(EXTRA_CPPFLAGS) COMPILE = $(CC) $(CMODEFLAGS) $(CPPFLAGS) $(CMAINTAINERFLAGS) $(CFLAGS) $(INCLUDES) COMPILE_CXX = $(CXX) $(CXXMODEFLAGS) $(CPPFLAGS) $(CXXMAINTAINERFLAGS) $(CXXFLAGS) $(INCLUDES) @@ -199,6 +200,19 @@ COMPILE_JAVAHL_CXX = $(LIBTOOL) $(LTCXXF COMPILE_JAVAHL_JAVAC = $(JAVAC) $(JAVAC_FLAGS) COMPILE_JAVAHL_JAVAH = $(JAVAH) +# export an env variable so that the tests can run without being installed +TEST_SHLIB_VAR_JAVAHL=\ + if [ "@SVN_APR_SHLIB_PATH_VAR@" = "DYLD_LIBRARY_PATH" ]; then \ + for d in $(abs_builddir)/subversion/libsvn_*; do \ + if [ -n "$$DYLD_LIBRARY_PATH" ]; then \ + @SVN_APR_SHLIB_PATH_VAR@="$$@SVN_APR_SHLIB_PATH_VAR@:$$d/.libs"; \ + else \ + @SVN_APR_SHLIB_PATH_VAR@="$$d/.libs"; \ + fi; \ + done; \ + export @SVN_APR_SHLIB_PATH_VAR@; \ + fi; + # special compilation for files destined for cxxhl COMPILE_CXXHL_CXX = $(LIBTOOL) $(LTCXXFLAGS) --mode=compile $(COMPILE_CXX) $(LT_CFLAGS) $(CXXHL_INCLUDES) -o $@ -c @@ -465,11 +479,13 @@ clean-javahl: check-tigris-javahl: javahl-compat @FIX_JAVAHL_LIB@ - $(JAVA) "-Dtest.rootdir=$(javahl_test_rootdir)" "-Dtest.srcdir=$(javahl_test_srcdir)" "-Dtest.rooturl=$(BASE_URL)" "-Dtest.fstype=$(FS_TYPE)" -Djava.library.path=@JAVAHL_OBJDIR@:$(libdir) -classpath $(javahl_compat_tests_PATH):$(javahl_tests_CLASSPATH) "-Dtest.tests=$(JAVAHL_TESTS)" org.tigris.subversion.javahl.RunTests + $(TEST_SHLIB_VAR_JAVAHL) \ + $(JAVA) "-Dtest.rootdir=$(javahl_test_rootdir)" "-Dtest.srcdir=$(javahl_test_srcdir)" "-Dtest.rooturl=$(BASE_URL)" "-Dtest.fstype=$(FS_TYPE)" "-Djava.library.path=@JAVAHL_OBJDIR@:$(libdir)" -classpath "$(javahl_compat_tests_PATH):$(javahl_tests_CLASSPATH)" "-Dtest.tests=$(JAVAHL_TESTS)" org.tigris.subversion.javahl.RunTests check-apache-javahl: javahl @FIX_JAVAHL_LIB@ - $(JAVA) "-Dtest.rootdir=$(javahl_test_rootdir)" "-Dtest.srcdir=$(javahl_test_srcdir)" "-Dtest.rooturl=$(BASE_URL)" "-Dtest.fstype=$(FS_TYPE)" -Djava.library.path=@JAVAHL_OBJDIR@:$(libdir) -classpath $(javahl_tests_PATH):$(javahl_tests_CLASSPATH) "-Dtest.tests=$(JAVAHL_TESTS)" org.apache.subversion.javahl.RunTests + $(TEST_SHLIB_VAR_JAVAHL) \ + $(JAVA) "-Dtest.rootdir=$(javahl_test_rootdir)" "-Dtest.srcdir=$(javahl_test_srcdir)" "-Dtest.rooturl=$(BASE_URL)" "-Dtest.fstype=$(FS_TYPE)" "-Djava.library.path=@JAVAHL_OBJDIR@:$(libdir)" -classpath "$(javahl_tests_PATH):$(javahl_tests_CLASSPATH)" "-Dtest.tests=$(JAVAHL_TESTS)" org.apache.subversion.javahl.RunTests check-javahl: check-apache-javahl Modified: vendor/subversion/dist/NOTICE ============================================================================== --- vendor/subversion/dist/NOTICE Thu Feb 20 17:23:08 2014 (r262247) +++ vendor/subversion/dist/NOTICE Thu Feb 20 19:26:10 2014 (r262248) @@ -1,5 +1,5 @@ -Subversion -Copyright 2010 The Apache Software Foundation +Apache Subversion +Copyright 2013 The Apache Software Foundation This product includes software developed by many people, and distributed under Contributor License Agreements to The Apache Software Foundation Modified: vendor/subversion/dist/build-outputs.mk ============================================================================== --- vendor/subversion/dist/build-outputs.mk Thu Feb 20 17:23:08 2014 (r262247) +++ vendor/subversion/dist/build-outputs.mk Thu Feb 20 19:26:10 2014 (r262248) @@ -1870,82 +1870,82 @@ subversion/bindings/swig/perl/libsvn_swi $(COMPILE_SWIG_PL) $(canonicalized_srcdir)subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.c subversion/bindings/swig/perl/native/core.lo: subversion/bindings/swig/perl/native/core.c subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.h subversion/include/svn_client.h subversion/include/svn_delta.h subversion/include/svn_fs.h subversion/include/svn_ra.h subversion/include/svn_repos.h subversion/include/svn_wc.h subversion/svn_private_config.h - $(COMPILE_PL_WRAPPER) subversion/bindings/swig/perl/native/core.c + $(COMPILE_PL_WRAPPER) $(canonicalized_srcdir)subversion/bindings/swig/perl/native/core.c subversion/bindings/swig/perl/native/svn_client.lo: subversion/bindings/swig/perl/native/svn_client.c subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.h subversion/include/svn_fs.h subversion/include/svn_repos.h subversion/svn_private_config.h - $(COMPILE_PL_WRAPPER) subversion/bindings/swig/perl/native/svn_client.c + $(COMPILE_PL_WRAPPER) $(canonicalized_srcdir)subversion/bindings/swig/perl/native/svn_client.c subversion/bindings/swig/perl/native/svn_delta.lo: subversion/bindings/swig/perl/native/svn_delta.c subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.h subversion/include/svn_client.h subversion/include/svn_fs.h subversion/include/svn_ra.h subversion/include/svn_repos.h subversion/include/svn_wc.h subversion/svn_private_config.h - $(COMPILE_PL_WRAPPER) subversion/bindings/swig/perl/native/svn_delta.c + $(COMPILE_PL_WRAPPER) $(canonicalized_srcdir)subversion/bindings/swig/perl/native/svn_delta.c subversion/bindings/swig/perl/native/svn_diff.lo: subversion/bindings/swig/perl/native/svn_diff.c subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.h subversion/include/svn_client.h subversion/include/svn_delta.h subversion/include/svn_fs.h subversion/include/svn_ra.h subversion/include/svn_repos.h subversion/include/svn_wc.h subversion/svn_private_config.h - $(COMPILE_PL_WRAPPER) subversion/bindings/swig/perl/native/svn_diff.c + $(COMPILE_PL_WRAPPER) $(canonicalized_srcdir)subversion/bindings/swig/perl/native/svn_diff.c subversion/bindings/swig/perl/native/svn_fs.lo: subversion/bindings/swig/perl/native/svn_fs.c subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.h subversion/include/svn_client.h subversion/include/svn_ra.h subversion/include/svn_repos.h subversion/include/svn_wc.h subversion/svn_private_config.h - $(COMPILE_PL_WRAPPER) subversion/bindings/swig/perl/native/svn_fs.c + $(COMPILE_PL_WRAPPER) $(canonicalized_srcdir)subversion/bindings/swig/perl/native/svn_fs.c subversion/bindings/swig/perl/native/svn_ra.lo: subversion/bindings/swig/perl/native/svn_ra.c subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.h subversion/include/svn_client.h subversion/include/svn_fs.h subversion/include/svn_repos.h subversion/include/svn_wc.h subversion/svn_private_config.h - $(COMPILE_PL_WRAPPER) subversion/bindings/swig/perl/native/svn_ra.c + $(COMPILE_PL_WRAPPER) $(canonicalized_srcdir)subversion/bindings/swig/perl/native/svn_ra.c subversion/bindings/swig/perl/native/svn_repos.lo: subversion/bindings/swig/perl/native/svn_repos.c subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.h subversion/include/svn_client.h subversion/include/svn_ra.h subversion/include/svn_wc.h subversion/svn_private_config.h - $(COMPILE_PL_WRAPPER) subversion/bindings/swig/perl/native/svn_repos.c + $(COMPILE_PL_WRAPPER) $(canonicalized_srcdir)subversion/bindings/swig/perl/native/svn_repos.c subversion/bindings/swig/perl/native/svn_wc.lo: subversion/bindings/swig/perl/native/svn_wc.c subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.h subversion/include/svn_client.h subversion/include/svn_fs.h subversion/include/svn_repos.h subversion/svn_private_config.h - $(COMPILE_PL_WRAPPER) subversion/bindings/swig/perl/native/svn_wc.c + $(COMPILE_PL_WRAPPER) $(canonicalized_srcdir)subversion/bindings/swig/perl/native/svn_wc.c subversion/bindings/swig/python/core.lo: subversion/bindings/swig/python/core.c subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.h subversion/include/svn_client.h subversion/include/svn_delta.h subversion/include/svn_fs.h subversion/include/svn_ra.h subversion/include/svn_repos.h subversion/include/svn_wc.h subversion/svn_private_config.h - $(COMPILE_PY_WRAPPER) subversion/bindings/swig/python/core.c + $(COMPILE_PY_WRAPPER) $(canonicalized_srcdir)subversion/bindings/swig/python/core.c subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.lo: subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.c subversion/bindings/swig/proxy/swig_python_external_runtime.swg subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h subversion/include/private/svn_debug.h subversion/include/svn_auth.h subversion/include/svn_checksum.h subversion/include/svn_client.h subversion/include/svn_config.h subversion/include/svn_delta.h subversion/include/svn_diff.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_fs.h subversion/include/svn_hash.h subversion/include/svn_io.h subversion/include/svn_mergeinfo.h subversion/include/svn_opt.h subversion/include/svn_pools.h subversion/include/svn_props.h subversion/include/svn_ra.h subversion/include/svn_repos.h subversion/include/svn_string.h subversion/include/svn_types.h subversion/include/svn_wc.h subversion/svn_private_config.h $(COMPILE_SWIG_PY) $(canonicalized_srcdir)subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.c subversion/bindings/swig/python/svn_client.lo: subversion/bindings/swig/python/svn_client.c subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.h subversion/include/svn_fs.h subversion/include/svn_repos.h subversion/svn_private_config.h - $(COMPILE_PY_WRAPPER) subversion/bindings/swig/python/svn_client.c + $(COMPILE_PY_WRAPPER) $(canonicalized_srcdir)subversion/bindings/swig/python/svn_client.c subversion/bindings/swig/python/svn_delta.lo: subversion/bindings/swig/python/svn_delta.c subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.h subversion/include/svn_client.h subversion/include/svn_fs.h subversion/include/svn_ra.h subversion/include/svn_repos.h subversion/include/svn_wc.h subversion/svn_private_config.h - $(COMPILE_PY_WRAPPER) subversion/bindings/swig/python/svn_delta.c + $(COMPILE_PY_WRAPPER) $(canonicalized_srcdir)subversion/bindings/swig/python/svn_delta.c subversion/bindings/swig/python/svn_diff.lo: subversion/bindings/swig/python/svn_diff.c subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.h subversion/include/svn_client.h subversion/include/svn_delta.h subversion/include/svn_fs.h subversion/include/svn_ra.h subversion/include/svn_repos.h subversion/include/svn_wc.h subversion/svn_private_config.h - $(COMPILE_PY_WRAPPER) subversion/bindings/swig/python/svn_diff.c + $(COMPILE_PY_WRAPPER) $(canonicalized_srcdir)subversion/bindings/swig/python/svn_diff.c subversion/bindings/swig/python/svn_fs.lo: subversion/bindings/swig/python/svn_fs.c subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.h subversion/include/svn_client.h subversion/include/svn_ra.h subversion/include/svn_repos.h subversion/include/svn_wc.h subversion/svn_private_config.h - $(COMPILE_PY_WRAPPER) subversion/bindings/swig/python/svn_fs.c + $(COMPILE_PY_WRAPPER) $(canonicalized_srcdir)subversion/bindings/swig/python/svn_fs.c subversion/bindings/swig/python/svn_ra.lo: subversion/bindings/swig/python/svn_ra.c subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.h subversion/include/svn_client.h subversion/include/svn_fs.h subversion/include/svn_repos.h subversion/include/svn_wc.h subversion/svn_private_config.h - $(COMPILE_PY_WRAPPER) subversion/bindings/swig/python/svn_ra.c + $(COMPILE_PY_WRAPPER) $(canonicalized_srcdir)subversion/bindings/swig/python/svn_ra.c subversion/bindings/swig/python/svn_repos.lo: subversion/bindings/swig/python/svn_repos.c subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.h subversion/include/svn_client.h subversion/include/svn_ra.h subversion/include/svn_wc.h subversion/svn_private_config.h - $(COMPILE_PY_WRAPPER) subversion/bindings/swig/python/svn_repos.c + $(COMPILE_PY_WRAPPER) $(canonicalized_srcdir)subversion/bindings/swig/python/svn_repos.c subversion/bindings/swig/python/svn_wc.lo: subversion/bindings/swig/python/svn_wc.c subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.h subversion/include/svn_client.h subversion/include/svn_fs.h subversion/include/svn_repos.h subversion/svn_private_config.h - $(COMPILE_PY_WRAPPER) subversion/bindings/swig/python/svn_wc.c + $(COMPILE_PY_WRAPPER) $(canonicalized_srcdir)subversion/bindings/swig/python/svn_wc.c subversion/bindings/swig/ruby/core.lo: subversion/bindings/swig/ruby/core.c subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.h subversion/include/svn_client.h subversion/include/svn_delta.h subversion/include/svn_fs.h subversion/include/svn_ra.h subversion/include/svn_repos.h subversion/include/svn_wc.h subversion/svn_private_config.h - $(COMPILE_RB_WRAPPER) subversion/bindings/swig/ruby/core.c + $(COMPILE_RB_WRAPPER) $(canonicalized_srcdir)subversion/bindings/swig/ruby/core.c subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.lo: subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.c subversion/bindings/swig/proxy/swig_ruby_external_runtime.swg subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.h subversion/include/private/svn_debug.h subversion/include/svn_auth.h subversion/include/svn_checksum.h subversion/include/svn_client.h subversion/include/svn_config.h subversion/include/svn_delta.h subversion/include/svn_diff.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_fs.h subversion/include/svn_hash.h subversion/include/svn_io.h subversion/include/svn_mergeinfo.h subversion/include/svn_nls.h subversion/include/svn_opt.h subversion/include/svn_pools.h subversion/include/svn_props.h subversion/include/svn_ra.h subversion/include/svn_repos.h subversion/include/svn_string.h subversion/include/svn_time.h subversion/include/svn_types.h subversion/include/svn_utf.h subversion/include/svn_wc.h subv ersion/svn_private_config.h $(COMPILE_SWIG_RB) $(canonicalized_srcdir)subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.c subversion/bindings/swig/ruby/svn_client.lo: subversion/bindings/swig/ruby/svn_client.c subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.h subversion/include/svn_fs.h subversion/include/svn_repos.h subversion/svn_private_config.h - $(COMPILE_RB_WRAPPER) subversion/bindings/swig/ruby/svn_client.c + $(COMPILE_RB_WRAPPER) $(canonicalized_srcdir)subversion/bindings/swig/ruby/svn_client.c subversion/bindings/swig/ruby/svn_delta.lo: subversion/bindings/swig/ruby/svn_delta.c subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.h subversion/include/svn_client.h subversion/include/svn_fs.h subversion/include/svn_ra.h subversion/include/svn_repos.h subversion/include/svn_wc.h subversion/svn_private_config.h - $(COMPILE_RB_WRAPPER) subversion/bindings/swig/ruby/svn_delta.c + $(COMPILE_RB_WRAPPER) $(canonicalized_srcdir)subversion/bindings/swig/ruby/svn_delta.c subversion/bindings/swig/ruby/svn_diff.lo: subversion/bindings/swig/ruby/svn_diff.c subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.h subversion/include/svn_client.h subversion/include/svn_delta.h subversion/include/svn_fs.h subversion/include/svn_ra.h subversion/include/svn_repos.h subversion/include/svn_wc.h subversion/svn_private_config.h - $(COMPILE_RB_WRAPPER) subversion/bindings/swig/ruby/svn_diff.c + $(COMPILE_RB_WRAPPER) $(canonicalized_srcdir)subversion/bindings/swig/ruby/svn_diff.c subversion/bindings/swig/ruby/svn_fs.lo: subversion/bindings/swig/ruby/svn_fs.c subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.h subversion/include/svn_client.h subversion/include/svn_ra.h subversion/include/svn_repos.h subversion/include/svn_wc.h subversion/svn_private_config.h - $(COMPILE_RB_WRAPPER) subversion/bindings/swig/ruby/svn_fs.c + $(COMPILE_RB_WRAPPER) $(canonicalized_srcdir)subversion/bindings/swig/ruby/svn_fs.c subversion/bindings/swig/ruby/svn_ra.lo: subversion/bindings/swig/ruby/svn_ra.c subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.h subversion/include/svn_client.h subversion/include/svn_fs.h subversion/include/svn_repos.h subversion/include/svn_wc.h subversion/svn_private_config.h - $(COMPILE_RB_WRAPPER) subversion/bindings/swig/ruby/svn_ra.c + $(COMPILE_RB_WRAPPER) $(canonicalized_srcdir)subversion/bindings/swig/ruby/svn_ra.c subversion/bindings/swig/ruby/svn_repos.lo: subversion/bindings/swig/ruby/svn_repos.c subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.h subversion/include/svn_client.h subversion/include/svn_ra.h subversion/include/svn_wc.h subversion/svn_private_config.h - $(COMPILE_RB_WRAPPER) subversion/bindings/swig/ruby/svn_repos.c + $(COMPILE_RB_WRAPPER) $(canonicalized_srcdir)subversion/bindings/swig/ruby/svn_repos.c subversion/bindings/swig/ruby/svn_wc.lo: subversion/bindings/swig/ruby/svn_wc.c subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.h subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.h subversion/include/svn_client.h subversion/include/svn_fs.h subversion/include/svn_repos.h subversion/svn_private_config.h - $(COMPILE_RB_WRAPPER) subversion/bindings/swig/ruby/svn_wc.c + $(COMPILE_RB_WRAPPER) $(canonicalized_srcdir)subversion/bindings/swig/ruby/svn_wc.c subversion/libsvn_auth_gnome_keyring/gnome_keyring.lo: subversion/libsvn_auth_gnome_keyring/gnome_keyring.c subversion/include/private/svn_auth_private.h subversion/include/private/svn_debug.h subversion/include/svn_auth.h subversion/include/svn_checksum.h subversion/include/svn_config.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_hash.h subversion/include/svn_io.h subversion/include/svn_pools.h subversion/include/svn_string.h subversion/include/svn_types.h subversion/svn_private_config.h @@ -2231,7 +2231,7 @@ subversion/libsvn_ra_serf/serf.lo: subve subversion/libsvn_ra_serf/update.lo: subversion/libsvn_ra_serf/update.c subversion/include/private/svn_dav_protocol.h subversion/include/private/svn_debug.h subversion/include/private/svn_dep_compat.h subversion/include/private/svn_editor.h subversion/include/private/svn_fspath.h subversion/include/private/svn_ra_private.h subversion/include/private/svn_string_private.h subversion/include/private/svn_subr_private.h subversion/include/svn_auth.h subversion/include/svn_base64.h subversion/include/svn_checksum.h subversion/include/svn_config.h subversion/include/svn_dav.h subversion/include/svn_delta.h subversion/include/svn_dirent_uri.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_hash.h subversion/include/svn_io.h subversion/include/svn_mergeinfo.h subversion/include/svn_path.h subversion/include/svn_pools.h subversion/include/svn_props.h subversion/include/svn_ra.h subversion/include/svn_string.h subversion/include/svn_types.h subversion /include/svn_version.h subversion/include/svn_xml.h subversion/libsvn_ra/ra_loader.h subversion/libsvn_ra_serf/blncache.h subversion/libsvn_ra_serf/ra_serf.h subversion/svn_private_config.h -subversion/libsvn_ra_serf/util.lo: subversion/libsvn_ra_serf/util.c subversion/include/private/svn_dav_protocol.h subversion/include/private/svn_debug.h subversion/include/private/svn_dep_compat.h subversion/include/private/svn_editor.h subversion/include/private/svn_fspath.h subversion/include/private/svn_ra_private.h subversion/include/private/svn_subr_private.h subversion/include/svn_auth.h subversion/include/svn_checksum.h subversion/include/svn_config.h subversion/include/svn_dav.h subversion/include/svn_delta.h subversion/include/svn_dirent_uri.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_hash.h subversion/include/svn_io.h subversion/include/svn_mergeinfo.h subversion/include/svn_path.h subversion/include/svn_pools.h subversion/include/svn_props.h subversion/include/svn_ra.h subversion/include/svn_string.h subversion/include/svn_types.h subversion/include/svn_version.h subversion/include/svn_xml.h subversion/libsvn_ra/ra_loader.h subversion/libsvn_ra_serf/blncache.h subversion/libsvn_ra_serf/ra_serf.h subversion/svn_private_config.h +subversion/libsvn_ra_serf/util.lo: subversion/libsvn_ra_serf/util.c subversion/include/private/svn_auth_private.h subversion/include/private/svn_dav_protocol.h subversion/include/private/svn_debug.h subversion/include/private/svn_dep_compat.h subversion/include/private/svn_editor.h subversion/include/private/svn_fspath.h subversion/include/private/svn_ra_private.h subversion/include/private/svn_subr_private.h subversion/include/svn_auth.h subversion/include/svn_checksum.h subversion/include/svn_config.h subversion/include/svn_dav.h subversion/include/svn_delta.h subversion/include/svn_dirent_uri.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_hash.h subversion/include/svn_io.h subversion/include/svn_mergeinfo.h subversion/include/svn_path.h subversion/include/svn_pools.h subversion/include/svn_props.h subversion/include/svn_ra.h subversion/include/svn_string.h subversion/include/svn_types.h subversion/include/svn_version.h subversion/incl ude/svn_xml.h subversion/libsvn_ra/ra_loader.h subversion/libsvn_ra_serf/blncache.h subversion/libsvn_ra_serf/ra_serf.h subversion/svn_private_config.h subversion/libsvn_ra_serf/util_error.lo: subversion/libsvn_ra_serf/util_error.c subversion/include/private/svn_dav_protocol.h subversion/include/private/svn_debug.h subversion/include/private/svn_editor.h subversion/include/private/svn_error_private.h subversion/include/private/svn_subr_private.h subversion/include/svn_auth.h subversion/include/svn_checksum.h subversion/include/svn_config.h subversion/include/svn_dav.h subversion/include/svn_delta.h subversion/include/svn_dirent_uri.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_io.h subversion/include/svn_mergeinfo.h subversion/include/svn_pools.h subversion/include/svn_ra.h subversion/include/svn_string.h subversion/include/svn_types.h subversion/include/svn_utf.h subversion/include/svn_version.h subversion/libsvn_ra_serf/blncache.h subversion/libsvn_ra_serf/ra_serf.h @@ -2291,7 +2291,7 @@ subversion/libsvn_subr/adler32.lo: subve subversion/libsvn_subr/atomic.lo: subversion/libsvn_subr/atomic.c subversion/include/private/svn_atomic.h subversion/include/private/svn_debug.h subversion/include/private/svn_dep_compat.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_types.h -subversion/libsvn_subr/auth.lo: subversion/libsvn_subr/auth.c subversion/include/private/svn_debug.h subversion/include/private/svn_dep_compat.h subversion/include/private/svn_subr_private.h subversion/include/svn_auth.h subversion/include/svn_checksum.h subversion/include/svn_config.h subversion/include/svn_dso.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_hash.h subversion/include/svn_io.h subversion/include/svn_string.h subversion/include/svn_types.h subversion/include/svn_version.h subversion/libsvn_subr/auth.h subversion/svn_private_config.h +subversion/libsvn_subr/auth.lo: subversion/libsvn_subr/auth.c subversion/include/private/svn_auth_private.h subversion/include/private/svn_debug.h subversion/include/private/svn_dep_compat.h subversion/include/private/svn_subr_private.h subversion/include/svn_auth.h subversion/include/svn_checksum.h subversion/include/svn_config.h subversion/include/svn_dso.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_hash.h subversion/include/svn_io.h subversion/include/svn_string.h subversion/include/svn_types.h subversion/include/svn_version.h subversion/libsvn_subr/auth.h subversion/svn_private_config.h subversion/libsvn_subr/base64.lo: subversion/libsvn_subr/base64.c subversion/include/private/svn_debug.h subversion/include/private/svn_string_private.h subversion/include/private/svn_subr_private.h subversion/include/svn_base64.h subversion/include/svn_checksum.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_io.h subversion/include/svn_pools.h subversion/include/svn_string.h subversion/include/svn_types.h subversion/include/svn_version.h Modified: vendor/subversion/dist/build.conf ============================================================================== --- vendor/subversion/dist/build.conf Thu Feb 20 17:23:08 2014 (r262247) +++ vendor/subversion/dist/build.conf Thu Feb 20 19:26:10 2014 (r262248) @@ -71,9 +71,9 @@ test-scripts = bdb-test-scripts = -swig-python-opts = $(CPPFLAGS) -python -classic -swig-perl-opts = $(CPPFLAGS) -perl -nopm -noproxy -swig-ruby-opts = $(CPPFLAGS) -ruby +swig-python-opts = $(SWIG_CPPFLAGS) -python -classic +swig-perl-opts = $(SWIG_CPPFLAGS) -perl -nopm -noproxy +swig-ruby-opts = $(SWIG_CPPFLAGS) -ruby swig-languages = python perl ruby swig-dirs = subversion/bindings/swig/python Modified: vendor/subversion/dist/configure ============================================================================== --- vendor/subversion/dist/configure Thu Feb 20 17:23:08 2014 (r262247) +++ vendor/subversion/dist/configure Thu Feb 20 19:26:10 2014 (r262248) @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.69 for subversion 1.8.5. +# Generated by GNU Autoconf 2.69 for subversion 1.8.8. # # Report bugs to . # @@ -590,8 +590,8 @@ MAKEFLAGS= # Identity of this package. PACKAGE_NAME='subversion' PACKAGE_TARNAME='subversion' -PACKAGE_VERSION='1.8.5' -PACKAGE_STRING='subversion 1.8.5' +PACKAGE_VERSION='1.8.8' +PACKAGE_STRING='subversion 1.8.8' PACKAGE_BUGREPORT='http://subversion.apache.org/' PACKAGE_URL='' @@ -635,6 +635,7 @@ ac_includes_default="\ ac_subst_vars='LTLIBOBJS SVN_CONFIG_SCRIPT_FILES INCLUDE_OUTPUTS +SWIG_CPPFLAGS JAVAHL_COMPAT_TESTS_TARGET JAVAHL_TESTS_TARGET JAVA_CLASSPATH @@ -1456,7 +1457,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures subversion 1.8.5 to adapt to many kinds of systems. +\`configure' configures subversion 1.8.8 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1522,7 +1523,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of subversion 1.8.5:";; + short | recursive ) echo "Configuration of subversion 1.8.8:";; esac cat <<\_ACEOF @@ -1736,7 +1737,7 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -subversion configure 1.8.5 +subversion configure 1.8.8 generated by GNU Autoconf 2.69 Copyright (C) 2012 Free Software Foundation, Inc. @@ -2280,7 +2281,7 @@ cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by subversion $as_me 1.8.5, which was +It was created by subversion $as_me 1.8.8, which was generated by GNU Autoconf 2.69. Invocation command line was $ $0 $@ @@ -2660,8 +2661,8 @@ ac_configure="$SHELL $ac_aux_dir/configu -{ $as_echo "$as_me:${as_lineno-$LINENO}: Configuring Subversion 1.8.5" >&5 -$as_echo "$as_me: Configuring Subversion 1.8.5" >&6;} +{ $as_echo "$as_me:${as_lineno-$LINENO}: Configuring Subversion 1.8.8" >&5 +$as_echo "$as_me: Configuring Subversion 1.8.8" >&6;} abs_srcdir="`cd $srcdir && pwd`" @@ -25073,6 +25074,13 @@ if test "$CC" = "clang"; then fi +# Need to strip '-no-cpp-precomp' from CPPFLAGS for SWIG as well. +SWIG_CPPFLAGS="$CPPFLAGS" + + SWIG_CPPFLAGS=`echo "$SWIG_CPPFLAGS" | $SED -e 's/-no-cpp-precomp //'` + + + cat >>confdefs.h <<_ACEOF #define SVN_PATH_LOCAL_SEPARATOR '/' @@ -25662,7 +25670,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_wri # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by subversion $as_me 1.8.5, which was +This file was extended by subversion $as_me 1.8.8, which was generated by GNU Autoconf 2.69. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -25728,7 +25736,7 @@ _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ -subversion config.status 1.8.5 +subversion config.status 1.8.8 configured by $0, generated by GNU Autoconf 2.69, with options \\"\$ac_cs_config\\" Modified: vendor/subversion/dist/configure.ac ============================================================================== --- vendor/subversion/dist/configure.ac Thu Feb 20 17:23:08 2014 (r262247) +++ vendor/subversion/dist/configure.ac Thu Feb 20 19:26:10 2014 (r262248) @@ -1443,6 +1443,11 @@ if test "$CC" = "clang"; then SVN_STRIP_FLAG(CPPFLAGS, [-no-cpp-precomp ]) fi +# Need to strip '-no-cpp-precomp' from CPPFLAGS for SWIG as well. +SWIG_CPPFLAGS="$CPPFLAGS" +SVN_STRIP_FLAG(SWIG_CPPFLAGS, [-no-cpp-precomp ]) +AC_SUBST([SWIG_CPPFLAGS]) + dnl Since this is used only on Unix-y systems, define the path separator as '/' AC_DEFINE_UNQUOTED(SVN_PATH_LOCAL_SEPARATOR, '/', [Defined to be the path separator used on your local filesystem]) Modified: vendor/subversion/dist/subversion/include/private/svn_auth_private.h ============================================================================== --- vendor/subversion/dist/subversion/include/private/svn_auth_private.h Thu Feb 20 17:23:08 2014 (r262247) +++ vendor/subversion/dist/subversion/include/private/svn_auth_private.h Thu Feb 20 19:26:10 2014 (r262248) @@ -37,6 +37,24 @@ extern "C" { #endif /* __cplusplus */ +/** SSL server authority verification credential type. + * + * The followin auth parameters are available to the providers: + * + * - @c SVN_AUTH_PARAM_SSL_SERVER_FAILURES (@c apr_uint32_t*) + * - @c SVN_AUTH_PARAM_SSL_SERVER_CERT_INFO + * (@c svn_auth_ssl_server_cert_info_t*) + * + * The following optional auth parameters are relevant to the providers: + * + * - @c SVN_AUTH_PARAM_NO_AUTH_CACHE (@c void*) + * + * @since New in 1.9. + */ +#define SVN_AUTH_CRED_SSL_SERVER_AUTHORITY "svn.ssl.server.authority" + + + /* If you add a password type for a provider which stores * passwords on disk in encrypted form, remember to update * svn_auth__simple_save_creds_helper. Otherwise it will be @@ -213,6 +231,25 @@ svn_auth__ssl_client_cert_pw_set(svn_boo svn_boolean_t non_interactive, apr_pool_t *pool); +#if (defined(WIN32) && !defined(__MINGW32__)) || defined(DOXYGEN) +/** + * Set @a *provider to an authentication provider that implements + * ssl authority verification via the Windows CryptoApi. + * + * This provider automatically validates authority certificates with + * the CryptoApi, like Internet Explorer and the Windows network API do. + * This allows the rollout of root certificates via Windows Domain + * policies, instead of Subversion specific configuration. + * + * @note This function is only available on Windows. + */ +void +svn_auth__get_windows_ssl_server_authority_provider( + svn_auth_provider_object_t **provider, + apr_pool_t *pool); +#endif + + #ifdef __cplusplus } #endif /* __cplusplus */ Modified: vendor/subversion/dist/subversion/include/private/svn_diff_tree.h ============================================================================== --- vendor/subversion/dist/subversion/include/private/svn_diff_tree.h Thu Feb 20 17:23:08 2014 (r262247) +++ vendor/subversion/dist/subversion/include/private/svn_diff_tree.h Thu Feb 20 19:26:10 2014 (r262248) @@ -20,13 +20,13 @@ * ==================================================================== * @endcopyright * - * @file svn_wc.h + * @file svn_diff_tree.h * @brief Generic diff handler. Replacing the old svn_wc_diff_callbacks4_t * infrastructure */ -#ifndef SVN_DIFF_PROCESSOR_H -#define SVN_DIFF_PROCESSOR_H +#ifndef SVN_DIFF_TREE_H +#define SVN_DIFF_TREE_H #include "svn_types.h" @@ -353,5 +353,5 @@ svn_diff__source_create(svn_revnum_t rev } #endif /* __cplusplus */ -#endif /* SVN_DIFF_PROCESSOR_H */ +#endif /* SVN_DIFF_TREE_H */ Modified: vendor/subversion/dist/subversion/include/private/svn_mutex.h ============================================================================== --- vendor/subversion/dist/subversion/include/private/svn_mutex.h Thu Feb 20 17:23:08 2014 (r262247) +++ vendor/subversion/dist/subversion/include/private/svn_mutex.h Thu Feb 20 19:26:10 2014 (r262248) @@ -21,7 +21,7 @@ * @endcopyright * * @file svn_mutex.h - * @brief Strutures and functions for mutual exclusion + * @brief Structures and functions for mutual exclusion */ #ifndef SVN_MUTEX_H @@ -72,7 +72,7 @@ svn_mutex__init(svn_mutex__t **mutex, * thread to release the mutex again. Recursive locking are not supported. * * @note You should use #SVN_MUTEX__WITH_LOCK instead of explicit lock - * aquisition and release. + * acquisition and release. */ svn_error_t * svn_mutex__lock(svn_mutex__t *mutex); @@ -88,19 +88,19 @@ svn_mutex__lock(svn_mutex__t *mutex); * reported in the return value. * * @note You should use #SVN_MUTEX__WITH_LOCK instead of explicit lock - * aquisition and release. + * acquisition and release. */ svn_error_t * svn_mutex__unlock(svn_mutex__t *mutex, svn_error_t *err); -/** Aquires the @a mutex, executes the expression @a expr and finally +/** Acquires the @a mutex, executes the expression @a expr and finally * releases the @a mutex. If any of these steps fail, the function using * this macro will return an #svn_error_t. This macro guarantees that * the @a mutex will always be unlocked again if it got locked successfully * by the first step. * - * @note Prefer using this macro instead of explicit lock aquisition and + * @note Prefer using this macro instead of explicit lock acquisition and * release. */ #define SVN_MUTEX__WITH_LOCK(mutex, expr) \ Modified: vendor/subversion/dist/subversion/include/svn_auth.h ============================================================================== --- vendor/subversion/dist/subversion/include/svn_auth.h Thu Feb 20 17:23:08 2014 (r262247) +++ vendor/subversion/dist/subversion/include/svn_auth.h Thu Feb 20 19:26:10 2014 (r262248) @@ -966,7 +966,10 @@ svn_auth_get_keychain_ssl_client_cert_pw apr_pool_t *pool); #endif /* DARWIN || DOXYGEN */ -#if (!defined(DARWIN) && !defined(WIN32)) || defined(DOXYGEN) +/* Note that the gnome keyring unlock prompt related items below must be + * declared for all platforms in order to allow SWIG interfaces to be + * used regardless of the platform. */ + /** A type of callback function for obtaining the GNOME Keyring password. * * In this callback, the client should ask the user for default keyring @@ -996,7 +999,7 @@ typedef svn_error_t *(*svn_auth_gnome_ke * @c *SVN_AUTH_PARAM_GNOME_KEYRING_UNLOCK_PROMPT_FUNC. */ #define SVN_AUTH_PARAM_GNOME_KEYRING_UNLOCK_PROMPT_BATON "gnome-keyring-unlock-prompt-baton" - +#if (!defined(DARWIN) && !defined(WIN32)) || defined(DOXYGEN) /** * Get libsvn_auth_gnome_keyring version information. * Modified: vendor/subversion/dist/subversion/include/svn_client.h ============================================================================== --- vendor/subversion/dist/subversion/include/svn_client.h Thu Feb 20 17:23:08 2014 (r262247) +++ vendor/subversion/dist/subversion/include/svn_client.h Thu Feb 20 19:26:10 2014 (r262248) @@ -439,9 +439,17 @@ typedef struct svn_client_commit_info_t #define SVN_CLIENT_COMMIT_ITEM_TEXT_MODS 0x04 #define SVN_CLIENT_COMMIT_ITEM_PROP_MODS 0x08 #define SVN_CLIENT_COMMIT_ITEM_IS_COPY 0x10 -/** @since New in 1.2. */ +/** One of the flags for a commit item. The node has a lock token that + * should be released after a successful commit and, if the node is also + * modified, transferred to the server as part of the commit process. + * + * @since New in 1.2. */ #define SVN_CLIENT_COMMIT_ITEM_LOCK_TOKEN 0x20 -/** @since New in 1.8. */ +/** One of the flags for a commit item. The node is the 'moved here' + * side of a local move. This is used to check and enforce that the + * other side of the move is also included in the commit. + * + * @since New in 1.8. */ #define SVN_CLIENT_COMMIT_ITEM_MOVED_HERE 0x40 /** @} */ @@ -6449,7 +6457,7 @@ svn_client_open_ra_session2(svn_ra_sessi apr_pool_t *result_pool, apr_pool_t *scratch_pool); -/** Similar to svn_client_open_ra_session(), but with @ wri_abspath +/** Similar to svn_client_open_ra_session2(), but with @ wri_abspath * always passed as NULL, and with the same pool used as both @a * result_pool and @a scratch_pool. * Modified: vendor/subversion/dist/subversion/include/svn_config.h ============================================================================== --- vendor/subversion/dist/subversion/include/svn_config.h Thu Feb 20 17:23:08 2014 (r262247) +++ vendor/subversion/dist/subversion/include/svn_config.h Thu Feb 20 19:26:10 2014 (r262248) @@ -98,8 +98,11 @@ typedef struct svn_config_t svn_config_t #define SVN_CONFIG_CATEGORY_CONFIG "config" #define SVN_CONFIG_SECTION_AUTH "auth" +/** @since New in 1.6. */ #define SVN_CONFIG_OPTION_PASSWORD_STORES "password-stores" +/** @since New in 1.6. */ #define SVN_CONFIG_OPTION_KWALLET_WALLET "kwallet-wallet" +/** @since New in 1.6. */ #define SVN_CONFIG_OPTION_KWALLET_SVN_APPLICATION_NAME_WITH_PID "kwallet-svn-application-name-with-pid" /** @since New in 1.8. */ #define SVN_CONFIG_OPTION_SSL_CLIENT_CERT_FILE_PROMPT "ssl-client-cert-file-prompt" @@ -123,7 +126,9 @@ typedef struct svn_config_t svn_config_t #define SVN_CONFIG_OPTION_NO_UNLOCK "no-unlock" #define SVN_CONFIG_OPTION_MIMETYPES_FILE "mime-types-file" #define SVN_CONFIG_OPTION_PRESERVED_CF_EXTS "preserved-conflict-file-exts" +/** @since New in 1.7. */ #define SVN_CONFIG_OPTION_INTERACTIVE_CONFLICTS "interactive-conflicts" +/** @since New in 1.7. */ #define SVN_CONFIG_OPTION_MEMORY_CACHE_SIZE "memory-cache-size" #define SVN_CONFIG_SECTION_TUNNELS "tunnels" #define SVN_CONFIG_SECTION_AUTO_PROPS "auto-props" @@ -168,10 +173,12 @@ typedef struct svn_config_t svn_config_t /* We want this to be printed on two lines in the generated config file, * but we don't want the # character to end up in the variable. */ +#ifndef DOXYGEN_SHOULD_SKIP_THIS #define SVN_CONFIG__DEFAULT_GLOBAL_IGNORES_LINE_1 \ "*.o *.lo *.la *.al .libs *.so *.so.[0-9]* *.a *.pyc *.pyo __pycache__" #define SVN_CONFIG__DEFAULT_GLOBAL_IGNORES_LINE_2 \ "*.rej *~ #*# .#* .*.swp .DS_Store" +#endif #define SVN_CONFIG_DEFAULT_GLOBAL_IGNORES \ SVN_CONFIG__DEFAULT_GLOBAL_IGNORES_LINE_1 " " \ Modified: vendor/subversion/dist/subversion/include/svn_diff.h ============================================================================== --- vendor/subversion/dist/subversion/include/svn_diff.h Thu Feb 20 17:23:08 2014 (r262247) +++ vendor/subversion/dist/subversion/include/svn_diff.h Thu Feb 20 19:26:10 2014 (r262248) @@ -911,8 +911,8 @@ typedef struct svn_diff_hunk_t svn_diff_ /** * Allocate @a *stringbuf in @a result_pool, and read into it one line - * of the diff text of @a hunk. The first line returned is the hunk header. - * Any subsequent lines are unidiff data (starting with '+', '-', or ' '). + * of the diff text of @a hunk. The hunk header is not returned only the + * unidiff data lines (starting with '+', '-', or ' ') are returned. * If the @a hunk is being interpreted in reverse (i.e. the reverse * parameter of svn_diff_parse_next_patch() was @c TRUE), the diff * text will be returned in reversed form. @@ -922,6 +922,13 @@ typedef struct svn_diff_hunk_t svn_diff_ * hunk does not end with a newline character and @a eol is not NULL. * Temporary allocations will be performed in @a scratch_pool. * + * @note The hunk header information can be retrievied with the following + * functions: + * @see svn_diff_hunk_get_original_start() + * @see svn_diff_hunk_get_original_length() + * @see svn_diff_hunk_get_modified_start() + * @see svn_diff_hunk_get_modified_length() + * * @since New in 1.7. */ svn_error_t * Modified: vendor/subversion/dist/subversion/include/svn_dirent_uri.h ============================================================================== --- vendor/subversion/dist/subversion/include/svn_dirent_uri.h Thu Feb 20 17:23:08 2014 (r262247) +++ vendor/subversion/dist/subversion/include/svn_dirent_uri.h Thu Feb 20 19:26:10 2014 (r262248) @@ -646,8 +646,8 @@ svn_dirent_skip_ancestor(const char *par /** Return the relative path part of @a child_relpath that is below * @a parent_relpath, or just "" if @a parent_relpath is equal to - * @a child_relpath. If @a child_relpath is not below or equal to - * @a parent_relpath, return NULL. + * @a child_relpath. If @a child_relpath is not below @a parent_relpath, + * return NULL. * * @since New in 1.7. */ @@ -657,7 +657,7 @@ svn_relpath_skip_ancestor(const char *pa /** Return the URI-decoded relative path of @a child_uri that is below * @a parent_uri, or just "" if @a parent_uri is equal to @a child_uri. If - * @a child_uri is not below or equal to @a parent_uri, return NULL. + * @a child_uri is not below @a parent_uri, return NULL. * * Allocate the result in @a result_pool. * Modified: vendor/subversion/dist/subversion/include/svn_io.h ============================================================================== --- vendor/subversion/dist/subversion/include/svn_io.h Thu Feb 20 17:23:08 2014 (r262247) +++ vendor/subversion/dist/subversion/include/svn_io.h Thu Feb 20 19:26:10 2014 (r262248) @@ -182,9 +182,10 @@ svn_io_check_resolved_path(const char *p * may be @c NULL. If @a file is @c NULL, the file will be created but not * open. * - * If @a delete_when is #svn_io_file_del_on_close, then the @c APR_DELONCLOSE - * flag will be used when opening the file. The @c APR_BUFFERED flag will - * always be used. + * The file will be deleted according to @a delete_when. If that is + * #svn_io_file_del_on_pool_cleanup, it refers to @a result_pool. + * + * The @c APR_BUFFERED flag will always be used when opening the file. * * The first attempt will just append @a suffix. If the result is not * a unique name, then subsequent attempts will append a dot, @@ -248,8 +249,9 @@ svn_io_open_uniquely_named(apr_file_t ** * be possible to atomically rename the resulting file due to cross-device * issues.) * - * The file will be deleted according to @a delete_when. If @a delete_when - * is @c svn_io_file_del_on_close and @a file is @c NULL, the file will be + * The file will be deleted according to @a delete_when. If that is + * #svn_io_file_del_on_pool_cleanup, it refers to @a result_pool. If it + * is #svn_io_file_del_on_close and @a file is @c NULL, the file will be * deleted before this function returns. * * When passing @c svn_io_file_del_none please don't forget to eventually @@ -917,7 +919,7 @@ svn_stream_empty(apr_pool_t *pool); /** Return a stream allocated in @a pool which forwards all requests * to @a stream. Destruction is explicitly excluded from forwarding. * - * @see notes/destruction-of-stacked-resources + * @see http://subversion.apache.org/docs/community-guide/conventions.html#destruction-of-stacked-resources * * @since New in 1.4. */ @@ -972,7 +974,8 @@ svn_stream_open_writable(svn_stream_t ** * be possible to atomically rename the resulting file due to cross-device * issues.) * - * The file will be deleted according to @a delete_when. + * The file will be deleted according to @a delete_when. If that is + * #svn_io_file_del_on_pool_cleanup, it refers to @a result_pool. * * Temporary allocations will be performed in @a scratch_pool. * @@ -1589,8 +1592,8 @@ svn_io_stat_dirent2(const svn_io_dirent2 apr_pool_t *scratch_pool); -/** Similar to svn_io_stat_dirent2, but always passes FALSE for - * verify_truename. +/** Similar to svn_io_stat_dirent2(), but always passes FALSE for + * @a verify_truename. * * @since New in 1.7. * @deprecated Provided for backwards compatibility with the 1.7 API. @@ -1681,7 +1684,7 @@ svn_io_dir_walk(const char *dirname, * * @note An APR bug affects Windows: passing a NULL @a env does not * guarantee the invoked program to run with an empty environment when - * @a inherits is FALSE, the program may inherit its parent's environment. + * @a inherit is FALSE, the program may inherit its parent's environment. * Explicitly pass an empty @a env to get an empty environment. * * @since New in 1.8. Modified: vendor/subversion/dist/subversion/include/svn_repos.h ============================================================================== --- vendor/subversion/dist/subversion/include/svn_repos.h Thu Feb 20 17:23:08 2014 (r262247) +++ vendor/subversion/dist/subversion/include/svn_repos.h Thu Feb 20 19:26:10 2014 (r262248) @@ -298,8 +298,7 @@ typedef struct svn_repos_notify_t * the revision which just completed. */ svn_revnum_t revision; - /** For #svn_repos_notify_warning, the warning object. Must be cleared - by the consumer of the notification. */ + /** For #svn_repos_notify_warning, the warning object. */ const char *warning_str; svn_repos_notify_warning_t warning; Modified: vendor/subversion/dist/subversion/include/svn_version.h ============================================================================== --- vendor/subversion/dist/subversion/include/svn_version.h Thu Feb 20 17:23:08 2014 (r262247) +++ vendor/subversion/dist/subversion/include/svn_version.h Thu Feb 20 19:26:10 2014 (r262248) @@ -72,7 +72,7 @@ extern "C" { * * @since New in 1.1. */ -#define SVN_VER_PATCH 5 +#define SVN_VER_PATCH 8 /** @deprecated Provided for backward compatibility with the 1.0 API. */ @@ -95,7 +95,7 @@ extern "C" { * * Always change this at the same time as SVN_VER_NUMTAG. */ -#define SVN_VER_TAG " (r1542147)" +#define SVN_VER_TAG " (r1568071)" /** Number tag: a string describing the version. @@ -121,7 +121,7 @@ extern "C" { * When rolling a tarball, we automatically replace it with what we * guess to be the correct revision number. */ -#define SVN_VER_REVISION 1542147 +#define SVN_VER_REVISION 1568071 /* Version strings composed from the above definitions. */ Modified: vendor/subversion/dist/subversion/include/svn_wc.h ============================================================================== --- vendor/subversion/dist/subversion/include/svn_wc.h Thu Feb 20 17:23:08 2014 (r262247) +++ vendor/subversion/dist/subversion/include/svn_wc.h Thu Feb 20 19:26:10 2014 (r262248) @@ -2109,9 +2109,8 @@ typedef struct svn_wc_conflict_result_t * Allocate an #svn_wc_conflict_result_t structure in @a pool, * initialize and return it. * - * Set the @c choice field of the structure to @a choice, and @c - * merged_file to @a merged_file. Set all other fields to their @c - * _unknown, @c NULL or invalid value, respectively. Make only a shallow + * Set the @c choice field of the structure to @a choice, @c merged_file + * to @a merged_file, and @c save_merged to false. Make only a shallow * copy of the pointer argument @a merged_file. * * @since New in 1.5. @@ -4078,6 +4077,9 @@ typedef void (*svn_wc_status_func_t)(voi * @a ignore_patterns is an array of file patterns matching * unversioned files to ignore for the purposes of status reporting, * or @c NULL if the default set of ignorable file patterns should be used. + * Patterns from #SVN_PROP_IGNORE (and, as of 1.8, + * #SVN_PROP_INHERITABLE_IGNORES) properties are always used, even if not + * specified in @a ignore_patterns. * * If @a cancel_func is non-NULL, call it with @a cancel_baton while walking * to determine if the client has canceled the operation. Modified: vendor/subversion/dist/subversion/libsvn_client/copy.c ============================================================================== --- vendor/subversion/dist/subversion/libsvn_client/copy.c Thu Feb 20 17:23:08 2014 (r262247) +++ vendor/subversion/dist/subversion/libsvn_client/copy.c Thu Feb 20 19:26:10 2014 (r262248) @@ -314,6 +314,8 @@ do_wc_to_wc_moves(svn_boolean_t *timesta { const char *src_parent_abspath; svn_boolean_t lock_src, lock_dst; + const char *src_wcroot_abspath; + const char *dst_wcroot_abspath; svn_client__copy_pair_t *pair = APR_ARRAY_IDX(copy_pairs, i, svn_client__copy_pair_t *); @@ -326,6 +328,13 @@ do_wc_to_wc_moves(svn_boolean_t *timesta src_parent_abspath = svn_dirent_dirname(pair->src_abspath_or_url, iterpool); + SVN_ERR(svn_wc__get_wcroot(&src_wcroot_abspath, + ctx->wc_ctx, src_parent_abspath, + iterpool, iterpool)); + SVN_ERR(svn_wc__get_wcroot(&dst_wcroot_abspath, + ctx->wc_ctx, pair->dst_parent_abspath, + iterpool, iterpool)); + /* We now need to lock the right combination of batons. Four cases: 1) src_parent == dst_parent @@ -334,15 +343,18 @@ do_wc_to_wc_moves(svn_boolean_t *timesta 4) src_parent and dst_parent are disjoint We can handle 1) as either 2) or 3) */ if (strcmp(src_parent_abspath, pair->dst_parent_abspath) == 0 - || svn_dirent_is_child(src_parent_abspath, pair->dst_parent_abspath, - iterpool)) + || (svn_dirent_is_child(src_parent_abspath, pair->dst_parent_abspath, + NULL) + && !svn_dirent_is_child(src_parent_abspath, dst_wcroot_abspath, + NULL))) { lock_src = TRUE; lock_dst = FALSE; } else if (svn_dirent_is_child(pair->dst_parent_abspath, - src_parent_abspath, - iterpool)) + src_parent_abspath, NULL) + && !svn_dirent_is_child(pair->dst_parent_abspath, + src_wcroot_abspath, NULL)) { lock_src = FALSE; lock_dst = TRUE; Modified: vendor/subversion/dist/subversion/libsvn_client/log.c ============================================================================== --- vendor/subversion/dist/subversion/libsvn_client/log.c Thu Feb 20 17:23:08 2014 (r262247) +++ vendor/subversion/dist/subversion/libsvn_client/log.c Thu Feb 20 19:26:10 2014 (r262248) @@ -861,17 +861,19 @@ svn_client_log5(const apr_array_header_t actual_loc->url, pool)); /* Save us an RA layer round trip if we are on the repository root and - know the result in advance. All the revision data has already been - validated. + know the result in advance, or if we don't need multiple ranges. + All the revision data has already been validated. */ - if (strcmp(actual_loc->url, actual_loc->repos_root_url) == 0) + if (strcmp(actual_loc->url, actual_loc->repos_root_url) == 0 + || opt_rev_ranges->nelts <= 1) { svn_location_segment_t *segment = apr_pcalloc(pool, sizeof(*segment)); log_segments = apr_array_make(pool, 1, sizeof(segment)); segment->range_start = oldest_rev; segment->range_end = actual_loc->rev; - segment->path = ""; + segment->path = svn_uri_skip_ancestor(actual_loc->repos_root_url, + actual_loc->url, pool); APR_ARRAY_PUSH(log_segments, svn_location_segment_t *) = segment; } else Modified: vendor/subversion/dist/subversion/libsvn_client/prop_commands.c ============================================================================== --- vendor/subversion/dist/subversion/libsvn_client/prop_commands.c Thu Feb 20 17:23:08 2014 (r262247) +++ vendor/subversion/dist/subversion/libsvn_client/prop_commands.c Thu Feb 20 19:26:10 2014 (r262248) @@ -1201,6 +1201,7 @@ struct recursive_proplist_receiver_baton svn_wc_context_t *wc_ctx; /* Working copy context. */ svn_proplist_receiver2_t wrapped_receiver; /* Proplist receiver to call. */ void *wrapped_receiver_baton; /* Baton for the proplist receiver. */ + apr_array_header_t *iprops; /* Anchor, anchor_abspath pair for converting to relative paths */ const char *anchor; @@ -1216,6 +1217,27 @@ recursive_proplist_receiver(void *baton, { struct recursive_proplist_receiver_baton *b = baton; const char *path; + apr_array_header_t *iprops = NULL; + + if (b->iprops + && ! strcmp(local_abspath, b->anchor_abspath)) + { + /* Report iprops with the properties for the anchor */ + iprops = b->iprops; + b->iprops = NULL; + } + else if (b->iprops) + { + /* No report for the root? + Report iprops anyway */ + + SVN_ERR(b->wrapped_receiver(b->wrapped_receiver_baton, + b->anchor ? b->anchor : local_abspath, + NULL /* prop_hash */, + b->iprops, + scratch_pool)); + b->iprops = NULL; + } /* Attempt to convert absolute paths to relative paths for * presentation purposes, if needed. */ @@ -1230,7 +1252,7 @@ recursive_proplist_receiver(void *baton, path = local_abspath; return svn_error_trace(b->wrapped_receiver(b->wrapped_receiver_baton, - path, props, NULL, + path, props, iprops, scratch_pool)); } @@ -1370,6 +1392,7 @@ get_local_props(const char *path_or_url, svn_node_kind_t kind; apr_hash_t *changelist_hash = NULL; const char *local_abspath; + apr_array_header_t *iprops = NULL; SVN_ERR(svn_dirent_get_absolute(&local_abspath, path_or_url, scratch_pool)); @@ -1392,7 +1415,6 @@ get_local_props(const char *path_or_url, if (get_target_inherited_props) { - apr_array_header_t *iprops; const char *repos_root_url; SVN_ERR(svn_wc__get_iprops(&iprops, ctx->wc_ctx, local_abspath, @@ -1402,8 +1424,6 @@ get_local_props(const char *path_or_url, SVN_ERR(svn_client__iprop_relpaths_to_urls(iprops, repos_root_url, scratch_pool, scratch_pool)); - SVN_ERR(call_receiver(path_or_url, NULL, iprops, receiver, *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-vendor@FreeBSD.ORG Thu Feb 20 19:26:49 2014 Return-Path: Delivered-To: svn-src-vendor@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 457181C3; Thu, 20 Feb 2014 19:26:49 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 15B1B15DE; Thu, 20 Feb 2014 19:26:49 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s1KJQmph013401; Thu, 20 Feb 2014 19:26:48 GMT (envelope-from peter@svn.freebsd.org) Received: (from peter@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s1KJQmCs013400; Thu, 20 Feb 2014 19:26:48 GMT (envelope-from peter@svn.freebsd.org) Message-Id: <201402201926.s1KJQmCs013400@svn.freebsd.org> From: Peter Wemm Date: Thu, 20 Feb 2014 19:26:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org Subject: svn commit: r262249 - vendor/subversion/subversion-1.8.8 X-SVN-Group: vendor MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-vendor@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: SVN commit messages for the vendor work area tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 20 Feb 2014 19:26:49 -0000 Author: peter Date: Thu Feb 20 19:26:48 2014 New Revision: 262249 URL: http://svnweb.freebsd.org/changeset/base/262249 Log: Tag subversion-1.8.8 Added: vendor/subversion/subversion-1.8.8/ - copied from r262248, vendor/subversion/dist/ From owner-svn-src-vendor@FreeBSD.ORG Thu Feb 20 22:39:58 2014 Return-Path: Delivered-To: svn-src-vendor@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id A95AF9DF; Thu, 20 Feb 2014 22:39:58 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 9027F18E8; Thu, 20 Feb 2014 22:39:58 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s1KMdw85091425; Thu, 20 Feb 2014 22:39:58 GMT (envelope-from bapt@svn.freebsd.org) Received: (from bapt@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s1KMdtfN091407; Thu, 20 Feb 2014 22:39:55 GMT (envelope-from bapt@svn.freebsd.org) Message-Id: <201402202239.s1KMdtfN091407@svn.freebsd.org> From: Baptiste Daroussin Date: Thu, 20 Feb 2014 22:39:55 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org Subject: svn commit: r262266 - in vendor/dma: . dist dist/debian dist/debian/migrate dist/debian/source dist/test X-SVN-Group: vendor MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-vendor@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: SVN commit messages for the vendor work area tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 20 Feb 2014 22:39:58 -0000 Author: bapt Date: Thu Feb 20 22:39:55 2014 New Revision: 262266 URL: http://svnweb.freebsd.org/changeset/base/262266 Log: Import dma 89702b7f14 (2013-02-13) into vendors Added: vendor/dma/ vendor/dma/dist/ vendor/dma/dist/BSDmakefile vendor/dma/dist/INSTALL vendor/dma/dist/LICENSE vendor/dma/dist/Makefile (contents, props changed) vendor/dma/dist/Makefile.etc (contents, props changed) vendor/dma/dist/README.markdown vendor/dma/dist/TODO vendor/dma/dist/VERSION vendor/dma/dist/aliases_parse.y vendor/dma/dist/aliases_scan.l vendor/dma/dist/auth.conf (contents, props changed) vendor/dma/dist/base64.c (contents, props changed) vendor/dma/dist/conf.c (contents, props changed) vendor/dma/dist/crypto.c (contents, props changed) vendor/dma/dist/debian/ vendor/dma/dist/debian/NEWS vendor/dma/dist/debian/README.Debian vendor/dma/dist/debian/changelog vendor/dma/dist/debian/compat vendor/dma/dist/debian/control vendor/dma/dist/debian/copyright vendor/dma/dist/debian/dma-migrate.dirs vendor/dma/dist/debian/dma-migrate.install vendor/dma/dist/debian/dma-migrate.manpages vendor/dma/dist/debian/dma.dirs vendor/dma/dist/debian/dma.links vendor/dma/dist/debian/dma.lintian-overrides vendor/dma/dist/debian/migrate/ vendor/dma/dist/debian/migrate/Makefile (contents, props changed) vendor/dma/dist/debian/migrate/NEWS vendor/dma/dist/debian/migrate/dma-migrate.8 (contents, props changed) vendor/dma/dist/debian/migrate/dma-migrate.c (contents, props changed) vendor/dma/dist/debian/rules (contents, props changed) vendor/dma/dist/debian/source/ vendor/dma/dist/debian/source/format vendor/dma/dist/debian/source/options vendor/dma/dist/dfcompat.c (contents, props changed) vendor/dma/dist/dfcompat.h (contents, props changed) vendor/dma/dist/dma-mbox-create.c (contents, props changed) vendor/dma/dist/dma.8 (contents, props changed) vendor/dma/dist/dma.c (contents, props changed) vendor/dma/dist/dma.conf (contents, props changed) vendor/dma/dist/dma.h (contents, props changed) vendor/dma/dist/dns.c (contents, props changed) vendor/dma/dist/get-version.sh (contents, props changed) vendor/dma/dist/local.c (contents, props changed) vendor/dma/dist/mail.c (contents, props changed) vendor/dma/dist/net.c (contents, props changed) vendor/dma/dist/spool.c (contents, props changed) vendor/dma/dist/test/ vendor/dma/dist/test/quote.rfc2822 vendor/dma/dist/util.c (contents, props changed) Added: vendor/dma/dist/BSDmakefile ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ vendor/dma/dist/BSDmakefile Thu Feb 20 22:39:55 2014 (r262266) @@ -0,0 +1,28 @@ +# $DragonFly: src/libexec/dma/Makefile,v 1.5 2008/09/19 00:36:57 corecode Exp $ +# + +version!= sh get-version.sh + +CFLAGS+= -I${.CURDIR} +CFLAGS+= -DHAVE_REALLOCF -DHAVE_STRLCPY -DHAVE_GETPROGNAME +CFLAGS+= -DLIBEXEC_PATH='"${LIBEXEC}"' -DDMA_VERSION='"${version}"' +CFLAGS+= -DCONF_PATH='"${CONFDIR}"' + +DPADD= ${LIBSSL} ${LIBCRYPTO} +LDADD= -lssl -lcrypto + +PROG= dma +SRCS= aliases_parse.y aliases_scan.l base64.c conf.c crypto.c +SRCS+= dma.c dns.c local.c mail.c net.c spool.c util.c +MAN= dma.8 + +PREFIX?= /usr/local +LIBEXEC?= ${PREFIX}/libexec +CONFDIR?= ${PREFIX}/etc/dma + +BINOWN= root +BINGRP= mail +BINMODE=2555 +WARNS?= 6 + +.include Added: vendor/dma/dist/INSTALL ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ vendor/dma/dist/INSTALL Thu Feb 20 22:39:55 2014 (r262266) @@ -0,0 +1,28 @@ +Installing DMA: +=============== + +On most systems (with a development environment installed) you should be able to compile DMA with: + make + +Once it have compiled it successfully, you can install it with: + make install sendmail-link mailq-link install-spool-dirs install-etc + +Troubleshooting: +---------------- +On systems that do not default to a compatible "make" version, try using "gmake" or "pmake" instead of "make". Some known examples of this: +* Solaris 9 +* Solaris 10 + +Check that you have the following commands installed: +* cc - gcc is known to work +* lex - flex is known to work +* yacc - bison is kjnown to work +* make - BSD make and GNU make is knwon to work +* sh - Need to be POSIX compliant, dash, bash known to work +* install - GNU and BSD versions known to work +* openssl - Add the header location to C_INCLUDE_PATH if you get errors about "err.h" + +If you have all of these tools installed, set the CC, YACC, INSTALL, LEX and SH variable to point to the relevant location and command. + +Example: + make CC=gcc YACC=bison LEX=/usr/bin/flex SH=/bin/bash INSTALL=/usr/bin/install Added: vendor/dma/dist/LICENSE ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ vendor/dma/dist/LICENSE Thu Feb 20 22:39:55 2014 (r262266) @@ -0,0 +1,109 @@ +Copyright (c) 2008 The DragonFly Project. +Copyright (c) 2008-2011, Simon Schubert <2@0x2c.org>. +All rights reserved. + +This code is derived from software contributed to The DragonFly Project +by Simon Schubert <2@0x2c.org>. + +This code is derived from software contributed to The DragonFly Project +by Matthias Schmidt , University of Marburg, +Germany. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions +are met: + +1. Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. +2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in + the documentation and/or other materials provided with the + distribution. +3. Neither the name of The DragonFly Project nor the names of its + contributors may be used to endorse or promote products derived + from this software without specific, prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS +FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING, +BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED +AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +SUCH DAMAGE. + + +Copyright (c) 1995-2001 Kungliga Tekniska Högskolan +(Royal Institute of Technology, Stockholm, Sweden). +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions +are met: + +1. Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + +3. Neither the name of the Institute nor the names of its contributors + may be used to endorse or promote products derived from this software + without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND +ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +ARE DISCLAIMED. IN NO EVENT SHALL THE INSTITUTE OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +SUCH DAMAGE. + + +Copyright (c) 1998 Todd C. Miller + +Permission to use, copy, modify, and distribute this software for any +purpose with or without fee is hereby granted, provided that the above +copyright notice and this permission notice appear in all copies. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + + +Copyright (c) 1998, M. Warner Losh +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions +are met: +1. Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. +2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + +THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +SUCH DAMAGE. Added: vendor/dma/dist/Makefile ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ vendor/dma/dist/Makefile Thu Feb 20 22:39:55 2014 (r262266) @@ -0,0 +1,111 @@ +# +# Depending on your operating system, you might want to influence +# the conditional inclusion of some helper functions: +# +# Define HAVE_* (in caps) if your system already provides: +# reallocf +# strlcpy +# getprogname +# + +SH?= sh + +version= $(shell ${SH} get-version.sh) +debversion= $(shell ${SH} get-version.sh | sed -Ee 's/^v//;s/[.]([[:digit:]]+)[.](g[[:xdigit:]]+)$$/+\1+\2/') + +CC?= gcc +CFLAGS?= -O -pipe +LDADD?= -lssl -lcrypto -lresolv + +CFLAGS+= -Wall -DDMA_VERSION='"${version}"' -DLIBEXEC_PATH='"${LIBEXEC}"' -DCONF_PATH='"${CONFDIR}"' + +INSTALL?= install -p +CHGRP?= chgrp +CHMOD?= chmod + +PREFIX?= /usr/local +SBIN?= ${PREFIX}/sbin +LIBEXEC?= ${PREFIX}/lib +CONFDIR?= /etc/dma +MAN?= ${PREFIX}/share/man +VAR?= /var +DMASPOOL?= ${VAR}/spool/dma +VARMAIL?= ${VAR}/mail +SYMLINK?= -s # or empty to create hard link + +YACC?= yacc +LEX?= lex +LN?= ln + +OBJS= aliases_parse.o aliases_scan.o base64.o conf.o crypto.o +OBJS+= dma.o dns.o local.o mail.o net.o spool.o util.o +OBJS+= dfcompat.o + +all: dma dma-mbox-create + +clean: + -rm -f .depend dma dma-mbox-create *.[do] + -rm -f aliases_parse.[ch] aliases_scan.c + +install: all + ${INSTALL} -d ${DESTDIR}${SBIN} + ${INSTALL} -d ${DESTDIR}${MAN}/man8 ${DESTDIR}${LIBEXEC} + ${INSTALL} -m 2755 -o root -g mail dma ${DESTDIR}${SBIN} + ${INSTALL} -m 4754 -o root -g mail dma-mbox-create ${DESTDIR}${LIBEXEC} + ${INSTALL} -m 0644 dma.8 ${DESTDIR}${MAN}/man8/ + +sendmail-link: + cd ${DESTDIR}${SBIN} && ${LN} ${SYMLINK} dma sendmail + +mailq-link: + cd ${DESTDIR}${SBIN} && ${LN} ${SYMLINK} dma mailq + +install-spool-dirs: + ${INSTALL} -d -m 2775 -o root -g mail ${DESTDIR}${DMASPOOL} + ${INSTALL} -d -m 2775 -o root -g mail ${DESTDIR}${VARMAIL} + +permissions: + -${CHGRP} mail ${DESTDIR}${VARMAIL}/* + -${CHMOD} g+w ${DESTDIR}${VARMAIL}/* + -${CHMOD} 660 ${DESTDIR}${DMASPOOL}/flush + +install-etc: + ${INSTALL} -d ${DESTDIR}${CONFDIR} + @if [ -e ${DESTDIR}${CONFDIR}/dma.conf ]; then \ + echo "Not overwriting ${DESTDIR}${CONFDIR}/dma.conf."; \ + else \ + echo ${INSTALL} -m 644 -o root -g mail dma.conf ${DESTDIR}${CONFDIR}; \ + ${INSTALL} -m 644 -o root -g mail dma.conf ${DESTDIR}${CONFDIR}; \ + fi + @if [ -e ${DESTDIR}${CONFDIR}/auth.conf ]; then \ + echo "Not overwriting ${DESTDIR}${CONFDIR}/auth.conf."; \ + else \ + echo ${INSTALL} -m 640 -o root -g mail auth.conf ${DESTDIR}${CONFDIR}; \ + ${INSTALL} -m 640 -o root -g mail auth.conf ${DESTDIR}${CONFDIR}; \ + fi + +aliases_parse.c: aliases_parse.y + ${YACC} -d -o aliases_parse.c aliases_parse.y + +aliases_scan.c: aliases_scan.l + ${LEX} -t aliases_scan.l > aliases_scan.c + +.SUFFIXES: .c .o + +.c.o: + ${CC} ${CFLAGS} ${CPPFLAGS} -include dfcompat.h -o $@ -c $< + +dma: ${OBJS} + ${CC} ${LDFLAGS} -o $@ ${OBJS} ${LDADD} + + +dch: + dch --release-heuristic changelog -v ${debversion} + + +ppa: + @if [ -z '${DEB_DIST}' ]; then echo "please set DEB_DIST to build"; exit 1; fi + dch -v "${debversion}~${DEB_DIST}" -D ${DEB_DIST} "${DEB_DIST} build" -b + debuild -S -sa + ver=$$(dpkg-parsechangelog -n1 | awk '$$1 == "Version:" { print $$2 }'); \ + dput ppa:corecode/dma ../dma_$${ver}_source.changes Added: vendor/dma/dist/Makefile.etc ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ vendor/dma/dist/Makefile.etc Thu Feb 20 22:39:55 2014 (r262266) @@ -0,0 +1,15 @@ +# $DragonFly: src/etc/dma/Makefile,v 1.3 2008/02/12 22:10:20 matthias Exp $ + +FILESDIR= /etc/dma +SHAREOWN= root +SHAREGRP= mail +FILESMODE= 640 + +.if !exists(${DESTDIR}/etc/dma/auth.conf) +FILES+= auth.conf +.endif +.if !exists(${DESTDIR}/etc/dma/dma.conf) +FILES+= dma.conf +.endif + +.include Added: vendor/dma/dist/README.markdown ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ vendor/dma/dist/README.markdown Thu Feb 20 22:39:55 2014 (r262266) @@ -0,0 +1,32 @@ +dma -- DragonFly Mail Agent +=========================== + +dma is a small Mail Transport Agent (MTA), designed for home and +office use. It accepts mails from locally installed Mail User Agents (MUA) +and delivers the mails either locally or to a remote destination. +Remote delivery includes several features like TLS/SSL support and +SMTP authentication. + +dma is not intended as a replacement for real, big MTAs like sendmail(8) +or postfix(1). Consequently, dma does not listen on port 25 for +incoming connections. + + +Building +-------- + + make + + +Installation +------------ + + make install sendmail-link mailq-link install-spool-dirs install-etc + +See INSTALL for requirements and configuration options. + + +Contact +------- + +Simon Schubert <2@0x2c.org> Added: vendor/dma/dist/TODO ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ vendor/dma/dist/TODO Thu Feb 20 22:39:55 2014 (r262266) @@ -0,0 +1,5 @@ +- unquote/handle quoted local recipients +- use proper sysexit codes +- handle/use ESMTP extensions +- .forward support +- suggest way to run a queue flush on boot Added: vendor/dma/dist/VERSION ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ vendor/dma/dist/VERSION Thu Feb 20 22:39:55 2014 (r262266) @@ -0,0 +1 @@ +v0.9 Added: vendor/dma/dist/aliases_parse.y ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ vendor/dma/dist/aliases_parse.y Thu Feb 20 22:39:55 2014 (r262266) @@ -0,0 +1,112 @@ +%{ + +#include +#include +#include +#include "dma.h" + +extern int yylineno; +static void yyerror(const char *); +int yywrap(void); +int yylex(void); + +static void +yyerror(const char *msg) +{ + /** + * Because we do error '\n' below, we need to report the error + * one line above of what yylineno points to. + */ + syslog(LOG_CRIT, "aliases line %d: %s", yylineno - 1, msg); + fprintf(stderr, "aliases line %d: %s\n", yylineno - 1, msg); +} + +int +yywrap(void) +{ + return (1); +} + +%} + +%union { + char *ident; + struct stritem *strit; + struct alias *alias; +} + +%token T_IDENT +%token T_ERROR +%token T_EOF 0 + +%type dests +%type alias aliases + +%% + +start : aliases T_EOF + { + LIST_FIRST(&aliases) = $1; + } + +aliases : /* EMPTY */ + { + $$ = NULL; + } + | alias aliases + { + if ($2 != NULL && $1 != NULL) + LIST_INSERT_AFTER($2, $1, next); + else if ($2 == NULL) + $2 = $1; + $$ = $2; + } + ; + +alias : T_IDENT ':' dests '\n' + { + struct alias *al; + + if ($1 == NULL) + YYABORT; + al = calloc(1, sizeof(*al)); + if (al == NULL) + YYABORT; + al->alias = $1; + SLIST_FIRST(&al->dests) = $3; + $$ = al; + } + | error '\n' + { + YYABORT; + } + ; + +dests : T_IDENT + { + struct stritem *it; + + if ($1 == NULL) + YYABORT; + it = calloc(1, sizeof(*it)); + if (it == NULL) + YYABORT; + it->str = $1; + $$ = it; + } + | T_IDENT ',' dests + { + struct stritem *it; + + if ($1 == NULL) + YYABORT; + it = calloc(1, sizeof(*it)); + if (it == NULL) + YYABORT; + it->str = $1; + SLIST_NEXT(it, next) = $3; + $$ = it; + } + ; + +%% Added: vendor/dma/dist/aliases_scan.l ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ vendor/dma/dist/aliases_scan.l Thu Feb 20 22:39:55 2014 (r262266) @@ -0,0 +1,24 @@ +%{ + +#include +#include "aliases_parse.h" + +#define YY_NO_INPUT + +int yylex(void); +%} + +%option yylineno +%option nounput + +%% + +[^:,#[:space:][:cntrl:]]+ {yylval.ident = strdup(yytext); return T_IDENT;} +^([[:blank:]]*(#.*)?\n)+ ;/* ignore empty lines */ +[:,\n] return yytext[0]; +(\n?[[:blank:]]+|#.*)+ ;/* ignore whitespace and continuation */ +\\\n ;/* ignore continuation. not allowed in comments */ +. return T_ERROR; +<> return T_EOF; + +%% Added: vendor/dma/dist/auth.conf ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ vendor/dma/dist/auth.conf Thu Feb 20 22:39:55 2014 (r262266) @@ -0,0 +1,4 @@ +# $DragonFly: src/etc/dma/auth.conf,v 1.1 2008/02/02 18:24:00 matthias Exp $ +# +# SMTP authentication entries (currently AUTH LOGIN only) +# Format: user|my.smarthost.example.com:password Added: vendor/dma/dist/base64.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ vendor/dma/dist/base64.c Thu Feb 20 22:39:55 2014 (r262266) @@ -0,0 +1,135 @@ +/* + * Copyright (c) 1995-2001 Kungliga Tekniska Högskolan + * (Royal Institute of Technology, Stockholm, Sweden). + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * 3. Neither the name of the Institute nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE INSTITUTE OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include +#include + +#include "dma.h" + +static char base64_chars[] = + "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; + +static int +pos(char c) +{ + char *p; + for (p = base64_chars; *p; p++) + if (*p == c) + return p - base64_chars; + return -1; +} + + +int +base64_encode(const void *data, int size, char **str) +{ + char *s, *p; + int i; + int c; + const unsigned char *q; + + p = s = (char *) malloc(size * 4 / 3 + 4); + if (p == NULL) + return -1; + q = (const unsigned char *) data; + i = 0; + for (i = 0; i < size;) { + c = q[i++]; + c *= 256; + if (i < size) + c += q[i]; + i++; + c *= 256; + if (i < size) + c += q[i]; + i++; + p[0] = base64_chars[(c & 0x00fc0000) >> 18]; + p[1] = base64_chars[(c & 0x0003f000) >> 12]; + p[2] = base64_chars[(c & 0x00000fc0) >> 6]; + p[3] = base64_chars[(c & 0x0000003f) >> 0]; + if (i > size) + p[3] = '='; + if (i > size + 1) + p[2] = '='; + p += 4; + } + *p = 0; + *str = s; + return strlen(s); +} + +#define DECODE_ERROR 0xffffffff + +static unsigned int +token_decode(const char *token) +{ + int i; + unsigned int val = 0; + int marker = 0; + if (strlen(token) < 4) + return DECODE_ERROR; + for (i = 0; i < 4; i++) { + val *= 64; + if (token[i] == '=') + marker++; + else if (marker > 0) + return DECODE_ERROR; + else + val += pos(token[i]); + } + if (marker > 2) + return DECODE_ERROR; + return (marker << 24) | val; +} + +int +base64_decode(const char *str, void *data) +{ + const char *p; + unsigned char *q; + + q = data; + for (p = str; *p && (*p == '=' || strchr(base64_chars, *p)); p += 4) { + unsigned int val = token_decode(p); + unsigned int marker = (val >> 24) & 0xff; + if (val == DECODE_ERROR) + return -1; + *q++ = (val >> 16) & 0xff; + if (marker < 2) + *q++ = (val >> 8) & 0xff; + if (marker < 1) + *q++ = val & 0xff; + } + return q - (unsigned char *) data; +} + Added: vendor/dma/dist/conf.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ vendor/dma/dist/conf.c Thu Feb 20 22:39:55 2014 (r262266) @@ -0,0 +1,246 @@ +/* + * Copyright (c) 2008 The DragonFly Project. All rights reserved. + * + * This code is derived from software contributed to The DragonFly Project + * by Matthias Schmidt , University of Marburg, + * Germany. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name of The DragonFly Project nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific, prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include +#include +#include +#include +#include +#include +#include + +#include "dma.h" + +#define DP ": \t" +#define EQS " \t" + + +/* + * Remove trailing \n's + */ +void +trim_line(char *line) +{ + size_t linelen; + char *p; + + if ((p = strchr(line, '\n'))) + *p = (char)0; + + /* Escape leading dot in every case */ + linelen = strlen(line); + if (line[0] == '.') { + if ((linelen + 2) > 1000) { + syslog(LOG_CRIT, "Cannot escape leading dot. Buffer overflow"); + exit(1); + } + memmove((line + 1), line, (linelen + 1)); + line[0] = '.'; + } +} + +static void +chomp(char *str) +{ + size_t len = strlen(str); + + if (len == 0) + return; + if (str[len - 1] == '\n') + str[len - 1] = 0; +} + +/* + * Read the SMTP authentication config file + * + * file format is: + * user|host:password + * + * A line starting with # is treated as comment and ignored. + */ +void +parse_authfile(const char *path) +{ + char line[2048]; + struct authuser *au; + FILE *a; + char *data; + int lineno = 0; + + a = fopen(path, "r"); + if (a == NULL) { + errlog(1, "can not open auth file `%s'", path); + /* NOTREACHED */ + } + + while (!feof(a)) { + if (fgets(line, sizeof(line), a) == NULL) + break; + lineno++; + + chomp(line); + + /* We hit a comment */ + if (*line == '#') + continue; + /* Ignore empty lines */ + if (*line == 0) + continue; + + au = calloc(1, sizeof(*au)); + if (au == NULL) + errlog(1, NULL); + + data = strdup(line); + au->login = strsep(&data, "|"); + au->host = strsep(&data, DP); + au->password = data; + + if (au->login == NULL || + au->host == NULL || + au->password == NULL) { + errlogx(1, "syntax error in authfile %s:%d", + path, lineno); + /* NOTREACHED */ + } + + SLIST_INSERT_HEAD(&authusers, au, next); + } + + fclose(a); +} + +/* + * XXX TODO + * Check for bad things[TM] + */ +void +parse_conf(const char *config_path) +{ + char *word; + char *data; + FILE *conf; + char line[2048]; + int lineno = 0; + + conf = fopen(config_path, "r"); + if (conf == NULL) { + /* Don't treat a non-existing config file as error */ + if (errno == ENOENT) + return; + errlog(1, "can not open config `%s'", config_path); + /* NOTREACHED */ + } + + while (!feof(conf)) { + if (fgets(line, sizeof(line), conf) == NULL) + break; + lineno++; + + chomp(line); + + /* We hit a comment */ + if (strchr(line, '#')) + *strchr(line, '#') = 0; + + data = line; + word = strsep(&data, EQS); + + /* Ignore empty lines */ + if (word == NULL || *word == 0) + continue; + + if (data != NULL && *data != 0) + data = strdup(data); + else + data = NULL; + + if (strcmp(word, "SMARTHOST") == 0 && data != NULL) + config.smarthost = data; + else if (strcmp(word, "PORT") == 0 && data != NULL) + config.port = atoi(data); + else if (strcmp(word, "ALIASES") == 0 && data != NULL) + config.aliases = data; + else if (strcmp(word, "SPOOLDIR") == 0 && data != NULL) + config.spooldir = data; + else if (strcmp(word, "AUTHPATH") == 0 && data != NULL) + config.authpath= data; + else if (strcmp(word, "CERTFILE") == 0 && data != NULL) + config.certfile = data; + else if (strcmp(word, "MAILNAME") == 0 && data != NULL) + config.mailname = data; + else if (strcmp(word, "MASQUERADE") == 0 && data != NULL) { + char *user = NULL, *host = NULL; + if (strrchr(data, '@')) { + host = strrchr(data, '@'); + *host = 0; + host++; + user = data; + } else { + host = data; + } + if (host && *host == 0) + host = NULL; + if (user && *user == 0) + user = NULL; + config.masquerade_host = host; + config.masquerade_user = user; + } else if (strcmp(word, "STARTTLS") == 0 && data == NULL) + config.features |= STARTTLS; + else if (strcmp(word, "OPPORTUNISTIC_TLS") == 0 && data == NULL) + config.features |= TLS_OPP; + else if (strcmp(word, "SECURETRANSFER") == 0 && data == NULL) + config.features |= SECURETRANS; + else if (strcmp(word, "DEFER") == 0 && data == NULL) + config.features |= DEFER; + else if (strcmp(word, "INSECURE") == 0 && data == NULL) + config.features |= INSECURE; + else if (strcmp(word, "FULLBOUNCE") == 0 && data == NULL) + config.features |= FULLBOUNCE; + else if (strcmp(word, "NULLCLIENT") == 0 && data == NULL) + config.features |= NULLCLIENT; + else { + errlogx(1, "syntax error in %s:%d", config_path, lineno); + /* NOTREACHED */ + } + } + + if ((config.features & NULLCLIENT) && config.smarthost == NULL) { + errlogx(1, "%s: NULLCLIENT requires SMARTHOST", config_path); + /* NOTREACHED */ + } + + fclose(conf); +} Added: vendor/dma/dist/crypto.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ vendor/dma/dist/crypto.c Thu Feb 20 22:39:55 2014 (r262266) @@ -0,0 +1,312 @@ +/* + * Copyright (c) 2008 The DragonFly Project. All rights reserved. + * + * This code is derived from software contributed to The DragonFly Project + * by Matthias Schmidt , University of Marburg, + * Germany. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name of The DragonFly Project nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific, prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include +#include +#include +#include +#include +#include + +#include + +#include "dma.h" + +static int +init_cert_file(SSL_CTX *ctx, const char *path) +{ + int error; + + /* Load certificate into ctx */ + error = SSL_CTX_use_certificate_chain_file(ctx, path); + if (error < 1) { + syslog(LOG_ERR, "SSL: Cannot load certificate `%s': %s", path, ssl_errstr()); + return (-1); + } + + /* Add private key to ctx */ + error = SSL_CTX_use_PrivateKey_file(ctx, path, SSL_FILETYPE_PEM); + if (error < 1) { + syslog(LOG_ERR, "SSL: Cannot load private key `%s': %s", path, ssl_errstr()); + return (-1); + } + + /* + * Check the consistency of a private key with the corresponding + * certificate + */ + error = SSL_CTX_check_private_key(ctx); + if (error < 1) { + syslog(LOG_ERR, "SSL: Cannot check private key: %s", ssl_errstr()); + return (-1); + } + + return (0); +} + +int +smtp_init_crypto(int fd, int feature) +{ + SSL_CTX *ctx = NULL; +#if (OPENSSL_VERSION_NUMBER >= 0x00909000L) + const SSL_METHOD *meth = NULL; +#else + SSL_METHOD *meth = NULL; +#endif + X509 *cert; + int error; + + /* XXX clean up on error/close */ + /* Init SSL library */ + SSL_library_init(); + SSL_load_error_strings(); + + meth = TLSv1_client_method(); + + ctx = SSL_CTX_new(meth); + if (ctx == NULL) { + syslog(LOG_WARNING, "remote delivery deferred: SSL init failed: %s", ssl_errstr()); + return (1); + } + + /* User supplied a certificate */ + if (config.certfile != NULL) { + error = init_cert_file(ctx, config.certfile); + if (error) { + syslog(LOG_WARNING, "remote delivery deferred"); *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-vendor@FreeBSD.ORG Thu Feb 20 22:41:07 2014 Return-Path: Delivered-To: svn-src-vendor@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 67E03BF2; Thu, 20 Feb 2014 22:41:07 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 3B55318F6; Thu, 20 Feb 2014 22:41:07 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s1KMf7Sx092496; Thu, 20 Feb 2014 22:41:07 GMT (envelope-from bapt@svn.freebsd.org) Received: (from bapt@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s1KMf79s092495; Thu, 20 Feb 2014 22:41:07 GMT (envelope-from bapt@svn.freebsd.org) Message-Id: <201402202241.s1KMf79s092495@svn.freebsd.org> From: Baptiste Daroussin Date: Thu, 20 Feb 2014 22:41:07 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org Subject: svn commit: r262267 - vendor/dma/20140213 X-SVN-Group: vendor MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-vendor@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: SVN commit messages for the vendor work area tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 20 Feb 2014 22:41:07 -0000 Author: bapt Date: Thu Feb 20 22:41:06 2014 New Revision: 262267 URL: http://svnweb.freebsd.org/changeset/base/262267 Log: Tag dma 20140213 Added: vendor/dma/20140213/ - copied from r262266, vendor/dma/dist/ From owner-svn-src-vendor@FreeBSD.ORG Fri Feb 21 01:55:01 2014 Return-Path: Delivered-To: svn-src-vendor@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id E2EF1D51; Fri, 21 Feb 2014 01:55:01 +0000 (UTC) Received: from anubis.delphij.net (anubis.delphij.net [64.62.153.212]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 6615A1B8D; Fri, 21 Feb 2014 01:55:01 +0000 (UTC) Received: from zeta.ixsystems.com (unknown [69.198.165.132]) (using TLSv1 with cipher ECDHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) by anubis.delphij.net (Postfix) with ESMTPSA id 99DCF14847; Thu, 20 Feb 2014 17:55:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=delphij.net; s=anubis; t=1392947700; bh=IrDdKseFeAWCgSSrP4JExdaVt8VUxuXbLvLy8wVIMiE=; h=Date:From:Reply-To:To:Subject:References:In-Reply-To; b=gxjT1EH1IwydERmzuP2gMd0MswxrVwlKuAVbxaBkIB1YS0NxzlCjtZ2xUSGoJrtLJ UJOD4aeOz0HvVPsrjPQ6vU4jrFQ7+GPqbMoaKaIcmJLH0lhLBRuI+YMR9lKPJjtqQo ANbyeHVgcQBYlhJRoR9WdAgzFOQ6PIMviBJqix40= Message-ID: <5306B1F3.4060107@delphij.net> Date: Thu, 20 Feb 2014 17:54:59 -0800 From: Xin Li Organization: The FreeBSD Project MIME-Version: 1.0 To: Baptiste Daroussin , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org Subject: Re: svn commit: r262266 - in vendor/dma: . dist dist/debian dist/debian/migrate dist/debian/source dist/test References: <201402202239.s1KMdtfN091407@svn.freebsd.org> In-Reply-To: <201402202239.s1KMdtfN091407@svn.freebsd.org> X-Enigmail-Version: 1.6 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-BeenThere: svn-src-vendor@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list Reply-To: d@delphij.net List-Id: SVN commit messages for the vendor work area tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 21 Feb 2014 01:55:02 -0000 -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA512 On 02/20/14 14:39, Baptiste Daroussin wrote: > Author: bapt Date: Thu Feb 20 22:39:55 2014 New Revision: 262266 > URL: http://svnweb.freebsd.org/changeset/base/262266 > > Log: Import dma 89702b7f14 (2013-02-13) into vendors Are we going to remove sendmail? Personally I don't think it's a good idea to have two different delivery agents. Cheers, - -- Xin LI https://www.delphij.net/ FreeBSD - The Power to Serve! Live free or die -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.22 (FreeBSD) iQIcBAEBCgAGBQJTBrHzAAoJEJW2GBstM+nswM4P/AkX9HyfaUHGryv3WKprE6ef b4A9uKPzxTruUdj8Pg198ZjJo+KCu70s6PTXcPtD37lVnp8fv01OrU2VfwdVTxDr JPoGijxpjAlp+t8wDAxJFMPhG+G0yMceDg+fevFVfJUwHNfTaxyZFy25NLqbbxBI NarbWlOCXCHBg07g1fR5vRyZTuWcpJOq+SFq81gyDpNpA17w/DZPCXznbB9BbZ8f 4K7AxrXI9rtiC5JYGc0WIkpymt3Xo0pXbIovtTrctHl5FtgoGPi1ck7s6NMhBqt3 tr5WUN+J5rZLOUXGnKfPG+5zi6gl22wuFcx0J3m6tE2o0iXMGxadEoHmeMmbhv9l HBtuh6rPRHJzSdPcfuaCB2gK20fjX1o+DJHia+vaQFvjbpuAOTKkbwGxAQVsYoxO Bmltg8wamjG7bfMEk48lJIkPqVdWnkvHde23VG428+AN9h2w5+fXKqoChbIROoIQ tQOMW2mRuxM57TJCyRGb+yOhNJsQ08XMN7K2VcOD5E6BiIOq+jJVJSFJvfhfdLtD uRYjGZTQ04w21VbdOWnFGD+P2PxZG1DJGNDzz64rAMcqW4oaxnyY1vBgl7Ori5zX +Ltu32ySsv3OwA4vx4X7rJX1+dGLWVZZlLgY3jFuOeWd3AJCyHP76+0GjwtT+3Gg quciD53LQUg5skHNJx+j =5VB2 -----END PGP SIGNATURE----- From owner-svn-src-vendor@FreeBSD.ORG Fri Feb 21 08:04:58 2014 Return-Path: Delivered-To: svn-src-vendor@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 51E54A1F; Fri, 21 Feb 2014 08:04:58 +0000 (UTC) Received: from mail-wg0-x231.google.com (mail-wg0-x231.google.com [IPv6:2a00:1450:400c:c00::231]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 8F27A1D27; Fri, 21 Feb 2014 08:04:57 +0000 (UTC) Received: by mail-wg0-f49.google.com with SMTP id y10so2297392wgg.16 for ; Fri, 21 Feb 2014 00:04:55 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-type:content-disposition:in-reply-to:user-agent; bh=UqW+AbSnsbjsOP+s8Kl74/aXm2rCz0Kx8a7Wi29Y0nY=; b=AsyI1lJ3sreLHtjsCCvFXfZ197cHKM2p7AM3ClhzhvjBJ5+CRIEyrKJz+H524qflHZ sG3y+cE/95kP+hqHu0My8sub1ekXbhy6Lqt3AfDewtym11tz4kUBhbXN4lnKT5tInLSv abL2sCFdeauMDfMYbq/3Ur1nGssPl/9nrnBTLxjXGSfc00gB3aCVydacB7xI/cKUicq+ wch16VntxXlybih7Kb8N7XGByJHUdAMyB9JmSfVQrUE4r8/Dy0XjNnsGlnEd6Idi+i/d fnZXu1k84QqbWvJ87H2iQNN3Y36IXrAK4WVVbr4O/B88UlLMayppwu01PG3HXk3G5g3w Pt+g== X-Received: by 10.194.60.16 with SMTP id d16mr5729983wjr.46.1392969895081; Fri, 21 Feb 2014 00:04:55 -0800 (PST) Received: from ithaqua.etoilebsd.net (ithaqua.etoilebsd.net. [37.59.37.188]) by mx.google.com with ESMTPSA id u6sm5513252wif.6.2014.02.21.00.04.52 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Fri, 21 Feb 2014 00:04:52 -0800 (PST) Sender: Baptiste Daroussin Date: Fri, 21 Feb 2014 09:04:50 +0100 From: Baptiste Daroussin To: d@delphij.net Subject: Re: svn commit: r262266 - in vendor/dma: . dist dist/debian dist/debian/migrate dist/debian/source dist/test Message-ID: <20140221080448.GG1699@ithaqua.etoilebsd.net> References: <201402202239.s1KMdtfN091407@svn.freebsd.org> <5306B1F3.4060107@delphij.net> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="7lMq7vMTJT4tNk0a" Content-Disposition: inline In-Reply-To: <5306B1F3.4060107@delphij.net> User-Agent: Mutt/1.5.21 (2010-09-15) Cc: svn-src-all@freebsd.org, src-committers@freebsd.org, svn-src-vendor@freebsd.org X-BeenThere: svn-src-vendor@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: SVN commit messages for the vendor work area tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 21 Feb 2014 08:04:58 -0000 --7lMq7vMTJT4tNk0a Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, Feb 20, 2014 at 05:54:59PM -0800, Xin Li wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA512 >=20 > On 02/20/14 14:39, Baptiste Daroussin wrote: > > Author: bapt Date: Thu Feb 20 22:39:55 2014 New Revision: 262266=20 > > URL: http://svnweb.freebsd.org/changeset/base/262266 > >=20 > > Log: Import dma 89702b7f14 (2013-02-13) into vendors >=20 > Are we going to remove sendmail? Personally I don't think it's a good > idea to have two different delivery agents. >=20 That is not the initial goal, the initial goal is to be able do relay mail = or deliver them locally without anything listening on port 25, with something = easy to configure and with a very low footprint. That said, yes I do really think that we should remove sendmail from base, = if I remember correctly the discussion each time we talked about it the conclusi= on was we only need something able to relay mail to another mails server and be able to locally deliver mails, that is exactly the definition of dma. to be honnest dma needs a bit of work on how it handle its retry queue, but= that might not be long to improve. regards, Bapt --7lMq7vMTJT4tNk0a Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.15 (FreeBSD) iEYEARECAAYFAlMHCKAACgkQ8kTtMUmk6ExE+ACfbtIDePo+UGt9AgyrBT/L4b0H SyYAoKmAYEQ7WdcfvE/2QdqQ9XeGpa8l =3/eV -----END PGP SIGNATURE----- --7lMq7vMTJT4tNk0a-- From owner-svn-src-vendor@FreeBSD.ORG Fri Feb 21 18:03:50 2014 Return-Path: Delivered-To: svn-src-vendor@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 3196898; Fri, 21 Feb 2014 18:03:50 +0000 (UTC) Received: from zxy.spb.ru (zxy.spb.ru [195.70.199.98]) by mx1.freebsd.org (Postfix) with ESMTP id 9AD3A1B39; Fri, 21 Feb 2014 18:03:49 +0000 (UTC) Received: from slw by zxy.spb.ru with local (Exim 4.69 (FreeBSD)) (envelope-from ) id 1WGuRw-000KD9-Eh; Fri, 21 Feb 2014 22:03:48 +0400 Date: Fri, 21 Feb 2014 22:03:48 +0400 From: Slawa Olhovchenkov To: Baptiste Daroussin Subject: Re: svn commit: r262266 - in vendor/dma: . dist dist/debian dist/debian/migrate dist/debian/source dist/test Message-ID: <20140221180348.GA77368@zxy.spb.ru> References: <201402202239.s1KMdtfN091407@svn.freebsd.org> <5306B1F3.4060107@delphij.net> <20140221080448.GG1699@ithaqua.etoilebsd.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20140221080448.GG1699@ithaqua.etoilebsd.net> User-Agent: Mutt/1.5.21 (2010-09-15) X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: slw@zxy.spb.ru X-SA-Exim-Scanned: No (on zxy.spb.ru); SAEximRunCond expanded to false Cc: svn-src-all@freebsd.org, src-committers@freebsd.org, d@delphij.net, svn-src-vendor@freebsd.org X-BeenThere: svn-src-vendor@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: SVN commit messages for the vendor work area tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 21 Feb 2014 18:03:50 -0000 On Fri, Feb 21, 2014 at 09:04:50AM +0100, Baptiste Daroussin wrote: > On Thu, Feb 20, 2014 at 05:54:59PM -0800, Xin Li wrote: > > -----BEGIN PGP SIGNED MESSAGE----- > > Hash: SHA512 > > > > On 02/20/14 14:39, Baptiste Daroussin wrote: > > > Author: bapt Date: Thu Feb 20 22:39:55 2014 New Revision: 262266 > > > URL: http://svnweb.freebsd.org/changeset/base/262266 > > > > > > Log: Import dma 89702b7f14 (2013-02-13) into vendors > > > > Are we going to remove sendmail? Personally I don't think it's a good > > idea to have two different delivery agents. > > > That is not the initial goal, the initial goal is to be able do relay mail or > deliver them locally without anything listening on port 25, with something easy > to configure and with a very low footprint. This is may be done by specific submit.cf and settings in rc.conf > That said, yes I do really think that we should remove sendmail from base, if I > remember correctly the discussion each time we talked about it the conclusion > was we only need something able to relay mail to another mails server and be > able to locally deliver mails, that is exactly the definition of dma. > > to be honnest dma needs a bit of work on how it handle its retry queue, but that > might not be long to improve. > > regards, > Bapt From owner-svn-src-vendor@FreeBSD.ORG Sat Feb 22 01:09:14 2014 Return-Path: Delivered-To: svn-src-vendor@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 8E246A12; Sat, 22 Feb 2014 01:09:14 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 7714311CA; Sat, 22 Feb 2014 01:09:14 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s1M19E3u059557; Sat, 22 Feb 2014 01:09:14 GMT (envelope-from peter@svn.freebsd.org) Received: (from peter@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s1M19C5w059539; Sat, 22 Feb 2014 01:09:12 GMT (envelope-from peter@svn.freebsd.org) Message-Id: <201402220109.s1M19C5w059539@svn.freebsd.org> From: Peter Wemm Date: Sat, 22 Feb 2014 01:09:12 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org Subject: svn commit: r262321 - in vendor/serf/dist: . auth buckets build X-SVN-Group: vendor MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-vendor@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: SVN commit messages for the vendor work area tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 22 Feb 2014 01:09:14 -0000 Author: peter Date: Sat Feb 22 01:09:12 2014 New Revision: 262321 URL: http://svnweb.freebsd.org/changeset/base/262321 Log: Vendor import serf-1.3.4 Modified: vendor/serf/dist/CHANGES vendor/serf/dist/README vendor/serf/dist/SConstruct vendor/serf/dist/auth/auth.c vendor/serf/dist/auth/auth.h vendor/serf/dist/auth/auth_basic.c vendor/serf/dist/auth/auth_digest.c vendor/serf/dist/auth/auth_spnego.c vendor/serf/dist/auth/auth_spnego.h vendor/serf/dist/auth/auth_spnego_gss.c vendor/serf/dist/auth/auth_spnego_sspi.c vendor/serf/dist/buckets/headers_buckets.c vendor/serf/dist/buckets/response_buckets.c vendor/serf/dist/buckets/socket_buckets.c vendor/serf/dist/buckets/ssl_buckets.c vendor/serf/dist/build/check.py vendor/serf/dist/build/gen_def.py vendor/serf/dist/build/serf.pc.in vendor/serf/dist/context.c vendor/serf/dist/outgoing.c vendor/serf/dist/serf.h vendor/serf/dist/serf_private.h vendor/serf/dist/ssltunnel.c Modified: vendor/serf/dist/CHANGES ============================================================================== --- vendor/serf/dist/CHANGES Sat Feb 22 00:57:55 2014 (r262320) +++ vendor/serf/dist/CHANGES Sat Feb 22 01:09:12 2014 (r262321) @@ -1,4 +1,59 @@ -Serf 1.3.0 [2013-07-23, from /tags/1.3.0] +Serf 1.3.4 [2014-02-08, from /tags/1.3.4, rxxxx] + Fix issue #119: Endless loop during ssl tunnel setup with Negotiate authn + Fix issue #123: Can't setup ssl tunnel which sends Connection close header + Fix a race condition when initializing OpenSSL from multiple threads (r2263) + Fix issue #138: Incorrect pkg-config file when GSSAPI isn't configured + + +Serf 1.3.3 [2013-12-09, from /tags/1.3.3, r2242] + Fix issue 129: Try more addresses of multihomed servers + Handle X509_V_ERR_UNABLE_TO_VERIFY_LEAF_SIGNATURE correctly (r2225) + Return APR_TIMEUP from poll() to enable detecting connection timeouts (r2183) + + +Serf 1.3.2 [2013-10-04, from /tags/1.3.2, r2195] + Fix issue 130: HTTP headers should be treated case-insensitively + Fix issue 126: Compilation breaks with Codewarrior compiler + Fix crash during cleanup of SSL buckets in apr_terminate() (r2145) + Fix Windows build: Also export functions with capital letters in .def file + Fix host header when url contains a username or password (r2170) + Ensure less TCP package fragmentation on Windows (r2145) + Handle authentication for responses to HEAD requests (r2178,-9) + Improve serf_get: add option to add request headers, allow url with query, + allow HEAD requests (r2143,r2175,-6) + Improve RFC conformance: don't expect body for certain responses (r2011,-2) + Do not invoke progress callback when no data was received (r2144) + And more test suite fixes and build warning cleanups + SCons-related fixes: + Fix build when GSSAPI not in default include path (2155) + Fix OpenBSD build: always map all LIBPATH entries into RPATH (r2156) + Checksum generation in Windows shared libraries for release builds (2162) + Mac OS X: Use MAJOR version only in dylib install name (r2161) + Use both MAJOR and MINOR version for the shared library name (2163) + Fix the .pc file when installing serf in a non-default LIBDIR (r2191) + + +Serf 1.3.1 [2013-08-15, from /tags/1.3.1, r2138] + Fix issue 77: Endless loop if server doesn't accept Negotiate authentication. + Fix issue 114: ssl/tls renegotiation fails + Fix issue 120: error with ssl tunnel over proxy with KeepAlive off and + Basic authentication. + Fixed bugs with authentication (r2057,2115,2118) + SCons-related fixes: + Fix issue 111: add flag to set custom library path + Fix issue 112: add soname + Fix issue 113: add gssapi libs in the serf pc file + Fix issue 115: Setting RPATH on Solaris broken in SConstruct + Fix issue 116: scons check should return non-zero exit staths + Fix issue 121: make CFLAGS, LIBS, LINKFLAGS and CPPFLAGS take a space- + separated list of flags. + Fix issue 122: make scons PREFIX create the folder if it doesn't exist + Mac OS X: Fix scons --install-sandbox + Solaris: Fix build with cc, don't use unsupported compiler flags + Require SCons version 2.3.0 or higher now (for the soname support). + + +Serf 1.3.0 [2013-07-23, from /tags/1.3.0, r2074] Fix issue 83: use PATH rather than URI within an ssltunnel (r1952) Fix issue 108: improved error reporting from the underlying socket (r1951) NEW: Switch to the SCons build system; retire serfmake, serf.mak, autotools Modified: vendor/serf/dist/README ============================================================================== --- vendor/serf/dist/README Sat Feb 22 00:57:55 2014 (r262320) +++ vendor/serf/dist/README Sat Feb 22 01:09:12 2014 (r262321) @@ -18,14 +18,14 @@ kept to a minimum to provide high perfor 1.1. SCons build system -serf uses SCons 2.x for its build system. If it is not installed on +serf uses SCons 2.3 for its build system. If it is not installed on your system, then you can install it onto your system. If you do not have permissions, then you can download and install the "local" version into your home directory. When installed privately, simply create a symlink for 'scons' in your PATH to /path/to/scons/scons.py. Fetch the scons-local package: - http://prdownloads.sourceforge.net/scons/scons-local-2.0.1.tar.gz + http://prdownloads.sourceforge.net/scons/scons-local-2.3.0.tar.gz 1.2 Building serf @@ -54,6 +54,12 @@ distinct directory from the source), you $ scons -Y /path/to/serf/source +If you plan to install the library on a system that uses different +paths for architecture dependent files, specify LIBDIR. LIBDIR defaults +to /usr/local/lib otherwise. Example for a 64 bit GNU/Linux system: + +$ scons PREFIX=/usr/ LIBDIR=/usr/lib64 + At any point, the current settings can be examined: $ scons --help @@ -74,6 +80,13 @@ specified on the install command line: $ scons PREFIX=/some/path install +Distribution package maintainers regulary install to a buildroot, and +would normally use something like below in their build systems, with +placeholders for the specific paths: + +$ scons PREFIX=/usr/ LIBDIR=/usr/lib64 +$ scons install --install-sandbox=/path/to/buildroot + 1.4 Cleaning up the build Modified: vendor/serf/dist/SConstruct ============================================================================== --- vendor/serf/dist/SConstruct Sat Feb 22 00:57:55 2014 (r262320) +++ vendor/serf/dist/SConstruct Sat Feb 22 01:09:12 2014 (r262321) @@ -19,6 +19,8 @@ import sys import os import re +EnsureSConsVersion(2,3,0) + HEADER_FILES = ['serf.h', 'serf_bucket_types.h', 'serf_bucket_util.h', @@ -34,23 +36,35 @@ def _converter(val): if val == 'none': val = [] else: - val = val.split(',') + val = val.split(' ') return val def RawListVariable(key, help, default): """ The input parameters describe a 'raw string list' option. This class - accepts a comma separated list and converts it to a space separated - list. + accepts a space-separated string and converts it to a list. """ return (key, '%s' % (help), default, None, lambda val: _converter(val)) +# Custom path validator, creates directory when a specified option is set. +# To be used to ensure a PREFIX directory is only created when installing. +def createPathIsDirCreateWithTarget(target): + def my_validator(key, val, env): + build_targets = (map(str, BUILD_TARGETS)) + if target in build_targets: + return PathVariable.PathIsDirCreate(key, val, env) + else: + return PathVariable.PathAccept(key, val, env) + return my_validator + # default directories if sys.platform == 'win32': + default_incdir='..' default_libdir='..' default_prefix='Debug' else: - default_libdir='/usr' + default_incdir='/usr' + default_libdir='$PREFIX/lib' default_prefix='/usr/local' opts = Variables(files=[SAVED_CONFIG]) @@ -58,22 +72,26 @@ opts.AddVariables( PathVariable('PREFIX', 'Directory to install under', default_prefix, - PathVariable.PathIsDir), + createPathIsDirCreateWithTarget('install')), + PathVariable('LIBDIR', + 'Directory to install architecture dependent libraries under', + default_libdir, + createPathIsDirCreateWithTarget('install')), PathVariable('APR', "Path to apr-1-config, or to APR's install area", - default_libdir, + default_incdir, PathVariable.PathAccept), PathVariable('APU', "Path to apu-1-config, or to APR's install area", - default_libdir, + default_incdir, PathVariable.PathAccept), PathVariable('OPENSSL', "Path to OpenSSL's install area", - default_libdir, + default_incdir, PathVariable.PathIsDir), PathVariable('ZLIB', "Path to zlib's install area", - default_libdir, + default_incdir, PathVariable.PathIsDir), PathVariable('GSSAPI', "Path to GSSAPI's install area", @@ -86,14 +104,14 @@ opts.AddVariables( "Enable using a static compiled APR", False), RawListVariable('CC', "Command name or path of the C compiler", None), - RawListVariable('CFLAGS', "Extra flags for the C compiler (comma separated)", + RawListVariable('CFLAGS', "Extra flags for the C compiler (space-separated)", None), RawListVariable('LIBS', "Extra libraries passed to the linker, " - "e.g. -l (comma separated)", None), - RawListVariable('LINKFLAGS', "Extra flags for the linker (comma separated)", + "e.g. \"-l -l\" (space separated)", None), + RawListVariable('LINKFLAGS', "Extra flags for the linker (space-separated)", None), RawListVariable('CPPFLAGS', "Extra flags for the C preprocessor " - "(comma separated)", None), + "(space separated)", None), ) if sys.platform == 'win32': @@ -146,6 +164,8 @@ match = re.search('SERF_MAJOR_VERSION ([ re.DOTALL) MAJOR, MINOR, PATCH = [int(x) for x in match.groups()] env.Append(MAJOR=str(MAJOR)) +env.Append(MINOR=str(MINOR)) +env.Append(PATCH=str(PATCH)) # Calling external programs is okay if we're not cleaning or printing help. # (cleaning: no sense in fetching information; help: we may not know where @@ -181,10 +201,18 @@ opts.Save(SAVED_CONFIG, env) # PLATFORM-SPECIFIC BUILD TWEAKS thisdir = os.getcwd() -libdir = '$PREFIX/lib' +libdir = '$LIBDIR' incdir = '$PREFIX/include/serf-$MAJOR' -LIBNAME = 'libserf-${MAJOR}' +# This version string is used in the dynamic library name, and for Mac OS X also +# for the current_version and compatibility_version options in the .dylib +# +# Unfortunately we can't set the .dylib compatibility_version option separately +# from current_version, so don't use the PATCH level to avoid that build and +# runtime patch levels have to be identical. +env['SHLIBVERSION'] = '%d.%d.%d' % (MAJOR, MINOR, 0) + +LIBNAME = 'libserf-%d' % (MAJOR,) if sys.platform != 'win32': LIBNAMESTATIC = LIBNAME else: @@ -196,23 +224,17 @@ env.Append(RPATH=libdir, if sys.platform == 'darwin': # linkflags.append('-Wl,-install_name,@executable_path/%s.dylib' % (LIBNAME,)) env.Append(LINKFLAGS='-Wl,-install_name,%s/%s.dylib' % (thisdir, LIBNAME,)) - # 'man ld' says positive non-zero for the first number, so we add one. - # Mac's interpretation of compatibility is the same as our MINOR version. - env.Append(LINKFLAGS='-Wl,-compatibility_version,%d' % (MINOR+1,)) - env.Append(LINKFLAGS='-Wl,-current_version,%d.%d' % (MINOR+1, PATCH,)) if sys.platform != 'win32': ### gcc only. figure out appropriate test / better way to check these ### flags, and check for gcc. env.Append(CFLAGS='-std=c89') - env.Append(CCFLAGS=[ - '-Wdeclaration-after-statement', - '-Wmissing-prototypes', - ]) - ### -Wall is not available on Solaris + ### These warnings are not available on Solaris if sys.platform != 'sunos5': - env.Append(CCFLAGS='-Wall') + env.Append(CCFLAGS=['-Wdeclaration-after-statement', + '-Wmissing-prototypes', + '-Wall']) if debug: env.Append(CCFLAGS='-g') @@ -239,6 +261,7 @@ else: # Optimize for speed, use DLL runtime env.Append(CCFLAGS=['/O2', '/MD']) env.Append(CPPDEFINES='NDEBUG') + env.Append(LINKFLAGS='/RELEASE') # PLAN THE BUILD SHARED_SOURCES = [] @@ -334,28 +357,32 @@ else: # If build with gssapi, get its information and define SERF_HAVE_GSSAPI if gssapi and CALLOUT_OKAY: - env.ParseConfig('$GSSAPI --libs gssapi') + env.ParseConfig('$GSSAPI --cflags gssapi') + def parse_libs(env, cmd, unique=1): + env['GSSAPI_LIBS'] = cmd.strip() + return env.MergeFlags(cmd, unique) + env.ParseConfig('$GSSAPI --libs gssapi', parse_libs) env.Append(CPPDEFINES='SERF_HAVE_GSSAPI') if sys.platform == 'win32': env.Append(CPPDEFINES=['SERF_HAVE_SSPI']) -# On Solaris, the -R values that APR describes never make it into actual +# On some systems, the -R values that APR describes never make it into actual # RPATH flags. We'll manually map all directories in LIBPATH into new # flags to set RPATH values. -if sys.platform == 'sunos5': - for d in env['LIBPATH']: - env.Append(RPATH=d) +for d in env['LIBPATH']: + env.Append(RPATH=':'+d) # Set up the construction of serf-*.pc -# TODO: add gssapi libs pkgconfig = env.Textfile('serf-%d.pc' % (MAJOR,), env.File('build/serf.pc.in'), SUBST_DICT = { '@MAJOR@': str(MAJOR), '@PREFIX@': '$PREFIX', + '@LIBDIR@': '$LIBDIR', '@INCLUDE_SUBDIR@': 'serf-%d' % (MAJOR,), '@VERSION@': '%d.%d.%d' % (MAJOR, MINOR, PATCH), - '@LIBS@': '%s %s -lz' % (apu_libs, apr_libs), + '@LIBS@': '%s %s %s -lz' % (apu_libs, apr_libs, + env.get('GSSAPI_LIBS', '')), }) env.Default(lib_static, lib_shared, pkgconfig) @@ -371,16 +398,22 @@ if CALLOUT_OKAY: # INSTALLATION STUFF install_static = env.Install(libdir, lib_static) -install_shared = env.Install(libdir, lib_shared) +install_shared = env.InstallVersionedLib(libdir, lib_shared) if sys.platform == 'darwin': + # Change the shared library install name (id) to its final name and location. + # Notes: + # If --install-sandbox= is specified, install_shared_path will point + # to a path in the sandbox. We can't use that path because the sandbox is + # only a temporary location. The id should be the final target path. + # Also, we shouldn't use the complete version number for id, as that'll + # make applications depend on the exact major.minor.patch version of serf. + install_shared_path = install_shared[0].abspath + target_install_shared_path = os.path.join(libdir, '%s.dylib' % LIBNAME) env.AddPostAction(install_shared, ('install_name_tool -id %s %s' - % (install_shared_path, + % (target_install_shared_path, install_shared_path))) - ### construct shared lib symlinks. this also means install the lib - ### as libserf-2.1.0.0.dylib, then add the symlinks. - ### note: see InstallAs env.Alias('install-lib', [install_static, install_shared, ]) Modified: vendor/serf/dist/auth/auth.c ============================================================================== --- vendor/serf/dist/auth/auth.c Sat Feb 22 00:57:55 2014 (r262320) +++ vendor/serf/dist/auth/auth.c Sat Feb 22 01:09:12 2014 (r262321) @@ -23,7 +23,8 @@ #include static apr_status_t -default_auth_response_handler(peer_t peer, +default_auth_response_handler(const serf__authn_scheme_t *scheme, + peer_t peer, int code, serf_connection_t *conn, serf_request_t *request, @@ -151,6 +152,17 @@ static int handle_auth_headers(int code, if (!auth_hdr) continue; + if (code == 401) { + authn_info = serf__get_authn_info_for_server(conn); + } else { + authn_info = &ctx->proxy_authn_info; + } + + if (authn_info->failed_authn_types & scheme->type) { + /* Skip this authn type since we already tried it before. */ + continue; + } + /* Found a matching scheme */ status = APR_SUCCESS; @@ -159,11 +171,6 @@ static int handle_auth_headers(int code, serf__log_skt(AUTH_VERBOSE, __FILE__, conn->skt, "... matched: %s\n", scheme->name); - if (code == 401) { - authn_info = serf__get_authn_info_for_server(conn); - } else { - authn_info = &ctx->proxy_authn_info; - } /* If this is the first time we use this scheme on this context and/or this connection, make sure to initialize the authentication handler first. */ @@ -198,6 +205,12 @@ static int handle_auth_headers(int code, */ serf__log_skt(AUTH_VERBOSE, __FILE__, conn->skt, "%s authentication failed.\n", scheme->name); + + /* Clear per-request auth_baton when switching to next auth scheme. */ + request->auth_baton = NULL; + + /* Remember failed auth types to skip in future. */ + authn_info->failed_authn_types |= scheme->type; } return status; @@ -221,7 +234,7 @@ static int store_header_in_dict(void *ba char *auth_name, *c; /* We're only interested in xxxx-Authenticate headers. */ - if (strcmp(key, ab->header) != 0) + if (strcasecmp(key, ab->header) != 0) return 0; /* Extract the authentication scheme name. */ @@ -378,16 +391,16 @@ apr_status_t serf__handle_auth_response( authn_info = serf__get_authn_info_for_server(conn); if (authn_info->scheme) { validate_resp = authn_info->scheme->validate_response_func; - resp_status = validate_resp(HOST, sl.code, conn, request, response, - pool); + resp_status = validate_resp(authn_info->scheme, HOST, sl.code, + conn, request, response, pool); } /* Validate the response proxy authn headers. */ authn_info = &ctx->proxy_authn_info; if (!resp_status && authn_info->scheme) { validate_resp = authn_info->scheme->validate_response_func; - resp_status = validate_resp(PROXY, sl.code, conn, request, response, - pool); + resp_status = validate_resp(authn_info->scheme, PROXY, sl.code, + conn, request, response, pool); } if (resp_status) { Modified: vendor/serf/dist/auth/auth.h ============================================================================== --- vendor/serf/dist/auth/auth.h Sat Feb 22 00:57:55 2014 (r262320) +++ vendor/serf/dist/auth/auth.h Sat Feb 22 01:09:12 2014 (r262321) @@ -78,7 +78,8 @@ apr_status_t serf__setup_request_digest_ const char *method, const char *uri, serf_bucket_t *hdrs_bkt); -apr_status_t serf__validate_response_digest_auth(peer_t peer, +apr_status_t serf__validate_response_digest_auth(const serf__authn_scheme_t *scheme, + peer_t peer, int code, serf_connection_t *conn, serf_request_t *request, @@ -108,7 +109,8 @@ apr_status_t serf__setup_request_spnego_ const char *method, const char *uri, serf_bucket_t *hdrs_bkt); -apr_status_t serf__validate_response_spnego_auth(peer_t peer, +apr_status_t serf__validate_response_spnego_auth(const serf__authn_scheme_t *scheme, + peer_t peer, int code, serf_connection_t *conn, serf_request_t *request, Modified: vendor/serf/dist/auth/auth_basic.c ============================================================================== --- vendor/serf/dist/auth/auth_basic.c Sat Feb 22 00:57:55 2014 (r262320) +++ vendor/serf/dist/auth/auth_basic.c Sat Feb 22 01:09:12 2014 (r262321) @@ -48,7 +48,7 @@ serf__handle_basic_auth(int code, apr_status_t status; apr_pool_t *cred_pool; char *username, *password, *realm_name; - const char *eq, *realm; + const char *eq, *realm = NULL; /* Can't do Basic authentication if there's no callback to get username & password. */ Modified: vendor/serf/dist/auth/auth_digest.c ============================================================================== --- vendor/serf/dist/auth/auth_digest.c Sat Feb 22 00:57:55 2014 (r262320) +++ vendor/serf/dist/auth/auth_digest.c Sat Feb 22 01:09:12 2014 (r262321) @@ -96,8 +96,9 @@ random_cnonce(apr_pool_t *pool) return hex_encode((unsigned char*)buf, pool); } -static const char * -build_digest_ha1(const char *username, +static apr_status_t +build_digest_ha1(const char **out_ha1, + const char *username, const char *password, const char *realm_name, apr_pool_t *pool) @@ -113,12 +114,17 @@ build_digest_ha1(const char *username, realm_name, password); status = apr_md5(ha1, tmp, strlen(tmp)); + if (status) + return status; + + *out_ha1 = hex_encode(ha1, pool); - return hex_encode(ha1, pool); + return APR_SUCCESS; } -static const char * -build_digest_ha2(const char *uri, +static apr_status_t +build_digest_ha2(const char **out_ha2, + const char *uri, const char *method, const char *qop, apr_pool_t *pool) @@ -134,17 +140,21 @@ build_digest_ha2(const char *uri, method, uri); status = apr_md5(ha2, tmp, strlen(tmp)); + if (status) + return status; - return hex_encode(ha2, pool); + *out_ha2 = hex_encode(ha2, pool); + + return APR_SUCCESS; } else { /* TODO: auth-int isn't supported! */ + return APR_ENOTIMPL; } - - return NULL; } -static const char * -build_auth_header(digest_authn_info_t *digest_info, +static apr_status_t +build_auth_header(const char **out_header, + digest_authn_info_t *digest_info, const char *path, const char *method, apr_pool_t *pool) @@ -156,7 +166,9 @@ build_auth_header(digest_authn_info_t *d const char *response_hdr_hex; apr_status_t status; - ha2 = build_digest_ha2(path, method, digest_info->qop, pool); + status = build_digest_ha2(&ha2, path, method, digest_info->qop, pool); + if (status) + return status; hdr = apr_psprintf(pool, "Digest realm=\"%s\"," @@ -194,6 +206,9 @@ build_auth_header(digest_authn_info_t *d } status = apr_md5(response_hdr, response, strlen(response)); + if (status) + return status; + response_hdr_hex = hex_encode(response_hdr, pool); hdr = apr_psprintf(pool, "%s, response=\"%s\"", hdr, response_hdr_hex); @@ -207,7 +222,9 @@ build_auth_header(digest_authn_info_t *d digest_info->algorithm); } - return hdr; + *out_header = hdr; + + return APR_SUCCESS; } apr_status_t @@ -330,8 +347,8 @@ serf__handle_digest_auth(int code, digest_info->username = apr_pstrdup(digest_info->pool, username); digest_info->digest_nc++; - digest_info->ha1 = build_digest_ha1(username, password, digest_info->realm, - digest_info->pool); + status = build_digest_ha1(&digest_info->ha1, username, password, + digest_info->realm, digest_info->pool); apr_pool_destroy(cred_pool); @@ -339,7 +356,7 @@ serf__handle_digest_auth(int code, likes. */ serf_connection_set_max_outstanding_requests(conn, 0); - return APR_SUCCESS; + return status; } apr_status_t @@ -387,7 +404,7 @@ serf__setup_request_digest_auth(peer_t p serf_context_t *ctx = conn->ctx; serf__authn_info_t *authn_info; digest_authn_info_t *digest_info; - apr_status_t status = APR_SUCCESS; + apr_status_t status; if (peer == HOST) { authn_info = serf__get_authn_info_for_server(conn); @@ -421,8 +438,10 @@ serf__setup_request_digest_auth(peer_t p /* Build a new Authorization header. */ digest_info->header = (peer == HOST) ? "Authorization" : "Proxy-Authorization"; - value = build_auth_header(digest_info, path, method, - conn->pool); + status = build_auth_header(&value, digest_info, path, method, + conn->pool); + if (status) + return status; serf_bucket_headers_setn(hdrs_bkt, digest_info->header, value); @@ -431,14 +450,15 @@ serf__setup_request_digest_auth(peer_t p /* Store the uri of this request on the serf_request_t object, to make it available when validating the Authentication-Info header of the matching response. */ - request->auth_baton = path; + request->auth_baton = (void *)path; } - return status; + return APR_SUCCESS; } apr_status_t -serf__validate_response_digest_auth(peer_t peer, +serf__validate_response_digest_auth(const serf__authn_scheme_t *scheme, + peer_t peer, int code, serf_connection_t *conn, serf_request_t *request, @@ -453,6 +473,7 @@ serf__validate_response_digest_auth(peer const char *nc_str = NULL; serf_bucket_t *hdrs; serf_context_t *ctx = conn->ctx; + apr_status_t status; hdrs = serf_bucket_response_get_headers(response); @@ -516,7 +537,10 @@ serf__validate_response_digest_auth(peer } digest_info = authn_info->baton; - ha2 = build_digest_ha2(req_uri, "", qop, pool); + status = build_digest_ha2(&ha2, req_uri, "", qop, pool); + if (status) + return status; + tmp = apr_psprintf(pool, "%s:%s:%s:%s:%s:%s", digest_info->ha1, digest_info->nonce, nc_str, digest_info->cnonce, digest_info->qop, ha2); Modified: vendor/serf/dist/auth/auth_spnego.c ============================================================================== --- vendor/serf/dist/auth/auth_spnego.c Sat Feb 22 00:57:55 2014 (r262320) +++ vendor/serf/dist/auth/auth_spnego.c Sat Feb 22 01:09:12 2014 (r262321) @@ -181,7 +181,8 @@ typedef struct claim to be. The session key can only be used with the HTTP service on the target host. */ static apr_status_t -gss_api_get_credentials(char *token, apr_size_t token_len, +gss_api_get_credentials(serf_connection_t *conn, + char *token, apr_size_t token_len, const char *hostname, const char **buf, apr_size_t *buf_len, gss_authn_info_t *gss_info) @@ -202,6 +203,7 @@ gss_api_get_credentials(char *token, apr /* Establish a security context to the server. */ status = serf__spnego_init_sec_context( + conn, gss_info->gss_ctx, KRB_HTTP_SERVICE, hostname, &input_buf, @@ -212,7 +214,11 @@ gss_api_get_credentials(char *token, apr switch(status) { case APR_SUCCESS: - gss_info->state = gss_api_auth_completed; + if (output_buf.length == 0) { + gss_info->state = gss_api_auth_completed; + } else { + gss_info->state = gss_api_auth_in_progress; + } break; case APR_EAGAIN: gss_info->state = gss_api_auth_in_progress; @@ -242,6 +248,7 @@ do_auth(peer_t peer, int code, gss_authn_info_t *gss_info, serf_connection_t *conn, + serf_request_t *request, const char *auth_hdr, apr_pool_t *pool) { @@ -306,6 +313,14 @@ do_auth(peer_t peer, break; } + if (request->auth_baton && !token) { + /* We provided token with this request, but server responded with empty + authentication header. This means server rejected our credentials. + XXX: Probably we need separate error code for this case like + SERF_ERROR_AUTHN_CREDS_REJECTED? */ + return SERF_ERROR_AUTHN_FAILED; + } + /* If the server didn't provide us with a token, start with a new initial step in the SPNEGO authentication. */ if (!token) { @@ -314,14 +329,16 @@ do_auth(peer_t peer, } if (peer == HOST) { - status = gss_api_get_credentials(token, token_len, + status = gss_api_get_credentials(conn, + token, token_len, conn->host_info.hostname, &tmp, &tmp_len, gss_info); } else { char *proxy_host; apr_getnameinfo(&proxy_host, conn->ctx->proxy_address, 0); - status = gss_api_get_credentials(token, token_len, proxy_host, + status = gss_api_get_credentials(conn, + token, token_len, proxy_host, &tmp, &tmp_len, gss_info); } @@ -357,24 +374,32 @@ serf__init_spnego_connection(const serf_ serf_connection_t *conn, apr_pool_t *pool) { - gss_authn_info_t *gss_info; - apr_status_t status; - - gss_info = apr_pcalloc(conn->pool, sizeof(*gss_info)); - gss_info->pool = conn->pool; - gss_info->state = gss_api_auth_not_started; - gss_info->pstate = pstate_init; - status = serf__spnego_create_sec_context(&gss_info->gss_ctx, scheme, - gss_info->pool, pool); - - if (status) { - return status; - } + serf_context_t *ctx = conn->ctx; + serf__authn_info_t *authn_info; + gss_authn_info_t *gss_info = NULL; + /* For proxy authentication, reuse the gss context for all connections. + For server authentication, create a new gss context per connection. */ if (code == 401) { - conn->authn_baton = gss_info; + authn_info = &conn->authn_info; } else { - conn->proxy_authn_baton = gss_info; + authn_info = &ctx->proxy_authn_info; + } + gss_info = authn_info->baton; + + if (!gss_info) { + apr_status_t status; + + gss_info = apr_pcalloc(conn->pool, sizeof(*gss_info)); + gss_info->pool = conn->pool; + gss_info->state = gss_api_auth_not_started; + gss_info->pstate = pstate_init; + status = serf__spnego_create_sec_context(&gss_info->gss_ctx, scheme, + gss_info->pool, pool); + if (status) { + return status; + } + authn_info->baton = gss_info; } /* Make serf send the initial requests one by one */ @@ -397,13 +422,15 @@ serf__handle_spnego_auth(int code, apr_pool_t *pool) { serf_connection_t *conn = request->conn; - gss_authn_info_t *gss_info = (code == 401) ? conn->authn_baton : - conn->proxy_authn_baton; + serf_context_t *ctx = conn->ctx; + gss_authn_info_t *gss_info = (code == 401) ? conn->authn_info.baton : + ctx->proxy_authn_info.baton; return do_auth(code == 401 ? HOST : PROXY, code, gss_info, request->conn, + request, auth_hdr, pool); } @@ -418,8 +445,9 @@ serf__setup_request_spnego_auth(peer_t p const char *uri, serf_bucket_t *hdrs_bkt) { - gss_authn_info_t *gss_info = (peer == HOST) ? conn->authn_baton : - conn->proxy_authn_baton; + serf_context_t *ctx = conn->ctx; + gss_authn_info_t *gss_info = (peer == HOST) ? conn->authn_info.baton : + ctx->proxy_authn_info.baton; /* If we have an ongoing authentication handshake, the handler of the previous response will have created the authn headers for this request @@ -431,6 +459,10 @@ serf__setup_request_spnego_auth(peer_t p serf_bucket_headers_setn(hdrs_bkt, gss_info->header, gss_info->value); + /* Remember that we're using this request for authentication + handshake. */ + request->auth_baton = (void*) TRUE; + /* We should send each token only once. */ gss_info->header = NULL; gss_info->value = NULL; @@ -469,6 +501,7 @@ serf__setup_request_spnego_auth(peer_t p code, gss_info, conn, + request, 0l, /* no response authn header */ conn->pool); if (status) @@ -476,6 +509,11 @@ serf__setup_request_spnego_auth(peer_t p serf_bucket_headers_setn(hdrs_bkt, gss_info->header, gss_info->value); + + /* Remember that we're using this request for authentication + handshake. */ + request->auth_baton = (void*) TRUE; + /* We should send each token only once. */ gss_info->header = NULL; gss_info->value = NULL; @@ -486,19 +524,70 @@ serf__setup_request_spnego_auth(peer_t p return APR_SUCCESS; } +/** + * Baton passed to the get_auth_header callback function. + */ +typedef struct { + const char *hdr_name; + const char *auth_name; + const char *hdr_value; + apr_pool_t *pool; +} get_auth_header_baton_t; + +static int +get_auth_header_cb(void *baton, + const char *key, + const char *header) +{ + get_auth_header_baton_t *b = baton; + + /* We're only interested in xxxx-Authenticate headers. */ + if (strcasecmp(key, b->hdr_name) != 0) + return 0; + + /* Check if header value starts with interesting auth name. */ + if (strncmp(header, b->auth_name, strlen(b->auth_name)) == 0) { + /* Save interesting header value and stop iteration. */ + b->hdr_value = apr_pstrdup(b->pool, header); + return 1; + } + + return 0; +} + +static const char * +get_auth_header(serf_bucket_t *hdrs, + const char *hdr_name, + const char *auth_name, + apr_pool_t *pool) +{ + get_auth_header_baton_t b; + + b.auth_name = hdr_name; + b.hdr_name = auth_name; + b.hdr_value = NULL; + b.pool = pool; + + serf_bucket_headers_do(hdrs, get_auth_header_cb, &b); + + return b.hdr_value; +} + /* Function is called when 2xx responses are received. Normally we don't * have to do anything, except for the first response after the * authentication handshake. This specific response includes authentication * data which should be validated by the client (mutual authentication). */ apr_status_t -serf__validate_response_spnego_auth(peer_t peer, +serf__validate_response_spnego_auth(const serf__authn_scheme_t *scheme, + peer_t peer, int code, serf_connection_t *conn, serf_request_t *request, serf_bucket_t *response, apr_pool_t *pool) { + serf_context_t *ctx = conn->ctx; gss_authn_info_t *gss_info; const char *auth_hdr_name; @@ -511,10 +600,10 @@ serf__validate_response_spnego_auth(peer "Validate Negotiate response header.\n"); if (peer == HOST) { - gss_info = conn->authn_baton; + gss_info = conn->authn_info.baton; auth_hdr_name = "WWW-Authenticate"; } else { - gss_info = conn->proxy_authn_baton; + gss_info = ctx->proxy_authn_info.baton; auth_hdr_name = "Proxy-Authenticate"; } @@ -524,11 +613,23 @@ serf__validate_response_spnego_auth(peer apr_status_t status; hdrs = serf_bucket_response_get_headers(response); - auth_hdr_val = serf_bucket_headers_get(hdrs, auth_hdr_name); + auth_hdr_val = get_auth_header(hdrs, auth_hdr_name, scheme->name, + pool); - status = do_auth(peer, code, gss_info, conn, auth_hdr_val, pool); - if (status) - return status; + if (auth_hdr_val) { + status = do_auth(peer, code, gss_info, conn, request, auth_hdr_val, + pool); + if (status) { + return status; + } + } else { + /* No Authenticate headers, nothing to validate: authentication + completed.*/ + gss_info->state = gss_api_auth_completed; + + serf__log_skt(AUTH_VERBOSE, __FILE__, conn->skt, + "SPNEGO handshake completed.\n"); + } } if (gss_info->state == gss_api_auth_completed) { Modified: vendor/serf/dist/auth/auth_spnego.h ============================================================================== --- vendor/serf/dist/auth/auth_spnego.h Sat Feb 22 00:57:55 2014 (r262320) +++ vendor/serf/dist/auth/auth_spnego.h Sat Feb 22 01:09:12 2014 (r262321) @@ -88,14 +88,15 @@ serf__spnego_create_sec_context(serf__sp * Other returns values indicates error. */ apr_status_t -serf__spnego_init_sec_context(serf__spnego_context_t *ctx, - const char *service, - const char *hostname, - serf__spnego_buffer_t *input_buf, - serf__spnego_buffer_t *output_buf, - apr_pool_t *result_pool, - apr_pool_t *scratch_pool - ); +serf__spnego_init_sec_context(serf_connection_t *conn, + serf__spnego_context_t *ctx, + const char *service, + const char *hostname, + serf__spnego_buffer_t *input_buf, + serf__spnego_buffer_t *output_buf, + apr_pool_t *result_pool, + apr_pool_t *scratch_pool + ); /* * Reset a previously created security context so we can start with a new one. Modified: vendor/serf/dist/auth/auth_spnego_gss.c ============================================================================== --- vendor/serf/dist/auth/auth_spnego_gss.c Sat Feb 22 00:57:55 2014 (r262320) +++ vendor/serf/dist/auth/auth_spnego_gss.c Sat Feb 22 01:09:12 2014 (r262321) @@ -43,7 +43,7 @@ struct serf__spnego_context_t }; static void -log_error(int verbose_flag, const char *filename, +log_error(int verbose_flag, apr_socket_t *skt, serf__spnego_context_t *ctx, OM_uint32 err_maj_stat, OM_uint32 err_min_stat, @@ -70,7 +70,7 @@ log_error(int verbose_flag, const char * &stat_buff); } - serf__log(verbose_flag, filename, + serf__log_skt(verbose_flag, __FILE__, skt, "%s (%x,%d): %s\n", msg, err_maj_stat, err_min_stat, stat_buff.value); } @@ -89,7 +89,7 @@ cleanup_ctx(void *data) gss_maj_stat = gss_delete_sec_context(&gss_min_stat, &ctx->gss_ctx, GSS_C_NO_BUFFER); if(GSS_ERROR(gss_maj_stat)) { - log_error(AUTH_VERBOSE, __FILE__, ctx, + log_error(AUTH_VERBOSE, NULL, ctx, gss_maj_stat, gss_min_stat, "Error cleaning up GSS security context"); return SERF_ERROR_AUTHN_FAILED; @@ -146,7 +146,8 @@ serf__spnego_reset_sec_context(serf__spn } apr_status_t -serf__spnego_init_sec_context(serf__spnego_context_t *ctx, +serf__spnego_init_sec_context(serf_connection_t *conn, + serf__spnego_context_t *ctx, const char *service, const char *hostname, serf__spnego_buffer_t *input_buf, *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-vendor@FreeBSD.ORG Sat Feb 22 01:09:51 2014 Return-Path: Delivered-To: svn-src-vendor@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 9E5D3B47; Sat, 22 Feb 2014 01:09:51 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 6E2CE11D3; Sat, 22 Feb 2014 01:09:51 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s1M19pBE059673; Sat, 22 Feb 2014 01:09:51 GMT (envelope-from peter@svn.freebsd.org) Received: (from peter@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s1M19prT059672; Sat, 22 Feb 2014 01:09:51 GMT (envelope-from peter@svn.freebsd.org) Message-Id: <201402220109.s1M19prT059672@svn.freebsd.org> From: Peter Wemm Date: Sat, 22 Feb 2014 01:09:51 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org Subject: svn commit: r262322 - vendor/serf/serf-1.3.4 X-SVN-Group: vendor MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-vendor@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: SVN commit messages for the vendor work area tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 22 Feb 2014 01:09:51 -0000 Author: peter Date: Sat Feb 22 01:09:50 2014 New Revision: 262322 URL: http://svnweb.freebsd.org/changeset/base/262322 Log: Tag import of serf-1.3.4 Added: vendor/serf/serf-1.3.4/ - copied from r262321, vendor/serf/dist/