From 054a20b5bf6f50b2828faddc6a7dccc36224037f Mon Sep 17 00:00:00 2001 From: Carles Fernandez Date: Fri, 11 Oct 2019 11:57:33 +0200 Subject: [PATCH 1/2] Apply clang-format to the whole code tree --- .../volk_gnsssdr/lib/volk_gnsssdr_malloc.c | 2 +- .../lib/volk_gnsssdr_rank_archs.c | 3 +- .../volk_gnsssdr/tmpl/volk_gnsssdr.tmpl.c | 4 +- .../volk_gnsssdr/tmpl/volk_gnsssdr_cpu.tmpl.c | 2 + .../tmpl/volk_gnsssdr_machines.tmpl.c | 2 +- .../libs/libswiftcnav/cnav_msg.c | 5 +- src/core/libs/supl/asn-rrlp/.clang-format | 5 - src/core/libs/supl/asn-rrlp/Accuracy.c | 46 +- src/core/libs/supl/asn-rrlp/AccuracyOpt.c | 8 +- src/core/libs/supl/asn-rrlp/AcquisAssist.c | 20 +- src/core/libs/supl/asn-rrlp/AcquisAssist.h | 2 +- src/core/libs/supl/asn-rrlp/AcquisElement.c | 110 +- src/core/libs/supl/asn-rrlp/AcquisElement.h | 2 +- .../libs/supl/asn-rrlp/AddionalAngleFields.c | 34 +- .../supl/asn-rrlp/AddionalDopplerFields.c | 30 +- .../supl/asn-rrlp/AdditionalAssistanceData.c | 44 +- .../supl/asn-rrlp/AdditionalAssistanceData.h | 2 +- .../supl/asn-rrlp/AdditionalDopplerFields.c | 32 +- src/core/libs/supl/asn-rrlp/AlertFlag.c | 46 +- .../libs/supl/asn-rrlp/Almanac-KeplerianSet.c | 138 +- src/core/libs/supl/asn-rrlp/Almanac.c | 30 +- src/core/libs/supl/asn-rrlp/Almanac.h | 2 +- src/core/libs/supl/asn-rrlp/AlmanacElement.c | 170 +-- src/core/libs/supl/asn-rrlp/AntiSpoofFlag.c | 60 +- .../supl/asn-rrlp/AssistBTSData-R98-ExpOTD.c | 26 +- .../supl/asn-rrlp/AssistBTSData-R98-ExpOTD.h | 2 +- src/core/libs/supl/asn-rrlp/AssistBTSData.c | 50 +- src/core/libs/supl/asn-rrlp/AssistBTSData.h | 2 +- src/core/libs/supl/asn-rrlp/AssistanceData.c | 98 +- src/core/libs/supl/asn-rrlp/AssistanceData.h | 10 +- src/core/libs/supl/asn-rrlp/BCCHCarrier.c | 56 +- src/core/libs/supl/asn-rrlp/BIT_STRING.c | 19 +- src/core/libs/supl/asn-rrlp/BOOLEAN.c | 92 +- src/core/libs/supl/asn-rrlp/BSIC.c | 44 +- src/core/libs/supl/asn-rrlp/BSICAndCarrier.c | 20 +- src/core/libs/supl/asn-rrlp/BTSPosition.c | 56 +- .../libs/supl/asn-rrlp/BadSignalElement.c | 26 +- src/core/libs/supl/asn-rrlp/BitNumber.c | 46 +- .../libs/supl/asn-rrlp/CalcAssistanceBTS.c | 20 +- src/core/libs/supl/asn-rrlp/CellID.c | 44 +- src/core/libs/supl/asn-rrlp/CellIDAndLAC.c | 16 +- src/core/libs/supl/asn-rrlp/CellIDAndLAC.h | 2 +- src/core/libs/supl/asn-rrlp/ControlHeader.c | 90 +- src/core/libs/supl/asn-rrlp/ControlHeader.h | 14 +- .../libs/supl/asn-rrlp/DGANSSSgnElement.c | 64 +- src/core/libs/supl/asn-rrlp/DGPSCorrections.c | 40 +- src/core/libs/supl/asn-rrlp/DGPSCorrections.h | 2 +- src/core/libs/supl/asn-rrlp/ENUMERATED.c | 12 +- src/core/libs/supl/asn-rrlp/EOTDQuality.c | 28 +- .../libs/supl/asn-rrlp/EnvironmentCharacter.c | 56 +- .../asn-rrlp/EphemerisSubframe1Reserved.c | 68 +- src/core/libs/supl/asn-rrlp/ErrorCodes.c | 44 +- .../libs/supl/asn-rrlp/ExpOTDUncertainty.c | 66 +- src/core/libs/supl/asn-rrlp/ExpectedOTD.c | 56 +- .../asn-rrlp/Ext-GeographicalInformation.c | 20 +- .../libs/supl/asn-rrlp/Extended-reference.c | 28 +- .../libs/supl/asn-rrlp/ExtensionContainer.c | 50 +- src/core/libs/supl/asn-rrlp/FineRTD.c | 46 +- src/core/libs/supl/asn-rrlp/FixType.c | 46 +- src/core/libs/supl/asn-rrlp/FrameDrift.c | 48 +- src/core/libs/supl/asn-rrlp/FrameNumber.c | 56 +- .../libs/supl/asn-rrlp/GANSS-AssistData.c | 14 +- .../libs/supl/asn-rrlp/GANSS-ControlHeader.c | 30 +- .../libs/supl/asn-rrlp/GANSS-MsrSetElement.c | 54 +- .../libs/supl/asn-rrlp/GANSS-MsrSetElement.h | 4 +- .../libs/supl/asn-rrlp/GANSS-SgnElement.c | 114 +- .../libs/supl/asn-rrlp/GANSS-SgnElement.h | 2 +- .../libs/supl/asn-rrlp/GANSS-SgnTypeElement.c | 22 +- .../libs/supl/asn-rrlp/GANSS-SgnTypeElement.h | 2 +- .../libs/supl/asn-rrlp/GANSSAlmanacElement.c | 14 +- .../libs/supl/asn-rrlp/GANSSAlmanacModel.c | 66 +- .../libs/supl/asn-rrlp/GANSSAlmanacModel.h | 2 +- .../libs/supl/asn-rrlp/GANSSAssistanceData.c | 52 +- src/core/libs/supl/asn-rrlp/GANSSClockModel.c | 14 +- .../supl/asn-rrlp/GANSSCommonAssistData.c | 40 +- .../supl/asn-rrlp/GANSSCommonAssistData.h | 4 +- src/core/libs/supl/asn-rrlp/GANSSDataBit.c | 60 +- .../libs/supl/asn-rrlp/GANSSDataBitAssist.c | 46 +- .../libs/supl/asn-rrlp/GANSSDataBitAssist.h | 2 +- .../libs/supl/asn-rrlp/GANSSDiffCorrections.c | 22 +- .../libs/supl/asn-rrlp/GANSSDiffCorrections.h | 2 +- .../asn-rrlp/GANSSGenericAssistDataElement.c | 136 +- .../asn-rrlp/GANSSGenericAssistDataElement.h | 6 +- .../libs/supl/asn-rrlp/GANSSIonoStormFlags.c | 52 +- .../libs/supl/asn-rrlp/GANSSIonosphereModel.c | 44 +- .../supl/asn-rrlp/GANSSIonosphericModel.c | 26 +- .../libs/supl/asn-rrlp/GANSSLocationInfo.c | 104 +- .../libs/supl/asn-rrlp/GANSSLocationInfo.h | 10 +- .../libs/supl/asn-rrlp/GANSSMeasureInfo.c | 12 +- src/core/libs/supl/asn-rrlp/GANSSNavModel.c | 70 +- src/core/libs/supl/asn-rrlp/GANSSNavModel.h | 2 +- src/core/libs/supl/asn-rrlp/GANSSOrbitModel.c | 10 +- .../supl/asn-rrlp/GANSSPositioningMethod.c | 46 +- .../supl/asn-rrlp/GANSSRealTimeIntegrity.c | 16 +- .../libs/supl/asn-rrlp/GANSSRefLocation.c | 12 +- .../supl/asn-rrlp/GANSSRefMeasurementAssist.c | 26 +- .../supl/asn-rrlp/GANSSRefMeasurementAssist.h | 2 +- .../asn-rrlp/GANSSRefMeasurementElement.c | 102 +- .../asn-rrlp/GANSSRefMeasurementElement.h | 2 +- .../libs/supl/asn-rrlp/GANSSRefTimeInfo.c | 54 +- .../libs/supl/asn-rrlp/GANSSRefTimeInfo.h | 2 +- .../libs/supl/asn-rrlp/GANSSReferenceTime.c | 28 +- .../supl/asn-rrlp/GANSSSatelliteElement.c | 60 +- .../supl/asn-rrlp/GANSSSatelliteElement.h | 4 +- src/core/libs/supl/asn-rrlp/GANSSSignalID.c | 60 +- .../asn-rrlp/GANSSTOD-GSMTimeAssociation.c | 56 +- .../asn-rrlp/GANSSTOD-GSMTimeAssociation.h | 4 +- src/core/libs/supl/asn-rrlp/GANSSTOD.c | 46 +- .../libs/supl/asn-rrlp/GANSSTODUncertainty.c | 52 +- src/core/libs/supl/asn-rrlp/GANSSTODm.c | 46 +- .../supl/asn-rrlp/GANSSTimeModelElement.c | 74 +- .../supl/asn-rrlp/GANSSTimeModelElement.h | 2 +- src/core/libs/supl/asn-rrlp/GANSSUTCModel.c | 118 +- src/core/libs/supl/asn-rrlp/GPS-AssistData.c | 12 +- src/core/libs/supl/asn-rrlp/GPS-MeasureInfo.c | 12 +- src/core/libs/supl/asn-rrlp/GPS-MsrElement.c | 92 +- src/core/libs/supl/asn-rrlp/GPS-MsrElement.h | 2 +- .../libs/supl/asn-rrlp/GPS-MsrSetElement.c | 36 +- .../libs/supl/asn-rrlp/GPS-MsrSetElement.h | 2 +- .../libs/supl/asn-rrlp/GPSAssistanceData.c | 66 +- .../asn-rrlp/GPSReferenceTimeUncertainty.c | 20 +- src/core/libs/supl/asn-rrlp/GPSTOW23b.c | 46 +- src/core/libs/supl/asn-rrlp/GPSTOW24b.c | 46 +- src/core/libs/supl/asn-rrlp/GPSTOWAssist.c | 8 +- .../libs/supl/asn-rrlp/GPSTOWAssistElement.c | 48 +- .../libs/supl/asn-rrlp/GPSTOWAssistElement.h | 6 +- src/core/libs/supl/asn-rrlp/GPSTime.c | 20 +- .../asn-rrlp/GPSTimeAssistanceMeasurements.c | 70 +- .../asn-rrlp/GPSTimeAssistanceMeasurements.h | 2 +- src/core/libs/supl/asn-rrlp/GPSWeek.c | 46 +- src/core/libs/supl/asn-rrlp/GSMTime.c | 48 +- src/core/libs/supl/asn-rrlp/GSMTime.h | 2 +- src/core/libs/supl/asn-rrlp/INTEGER.c | 522 ++++---- .../libs/supl/asn-rrlp/IonosphericModel.c | 114 +- src/core/libs/supl/asn-rrlp/LAC.c | 44 +- src/core/libs/supl/asn-rrlp/LocErrorReason.c | 58 +- src/core/libs/supl/asn-rrlp/LocationError.c | 24 +- src/core/libs/supl/asn-rrlp/LocationInfo.c | 48 +- src/core/libs/supl/asn-rrlp/LocationInfo.h | 4 +- .../libs/supl/asn-rrlp/MeasureResponseTime.c | 52 +- src/core/libs/supl/asn-rrlp/MethodType.c | 34 +- src/core/libs/supl/asn-rrlp/MethodType.h | 2 +- src/core/libs/supl/asn-rrlp/ModuloTimeSlot.c | 62 +- .../libs/supl/asn-rrlp/MoreAssDataToBeSent.c | 56 +- src/core/libs/supl/asn-rrlp/MpathIndic.c | 44 +- .../supl/asn-rrlp/MsrAssistBTS-R98-ExpOTD.c | 26 +- .../supl/asn-rrlp/MsrAssistBTS-R98-ExpOTD.h | 2 +- src/core/libs/supl/asn-rrlp/MsrAssistBTS.c | 58 +- src/core/libs/supl/asn-rrlp/MsrAssistBTS.h | 2 +- .../supl/asn-rrlp/MsrAssistData-R98-ExpOTD.c | 16 +- src/core/libs/supl/asn-rrlp/MsrAssistData.c | 12 +- src/core/libs/supl/asn-rrlp/MsrPosition-Req.c | 96 +- src/core/libs/supl/asn-rrlp/MsrPosition-Req.h | 10 +- src/core/libs/supl/asn-rrlp/MsrPosition-Rsp.c | 102 +- src/core/libs/supl/asn-rrlp/MsrPosition-Rsp.h | 10 +- .../libs/supl/asn-rrlp/MultiFrameCarrier.c | 22 +- .../libs/supl/asn-rrlp/MultiFrameOffset.c | 64 +- src/core/libs/supl/asn-rrlp/MultipleSets.c | 38 +- src/core/libs/supl/asn-rrlp/MultipleSets.h | 2 +- src/core/libs/supl/asn-rrlp/NULL.c | 42 +- .../libs/supl/asn-rrlp/NativeEnumerated.c | 26 +- src/core/libs/supl/asn-rrlp/NativeInteger.c | 54 +- src/core/libs/supl/asn-rrlp/NativeInteger.h | 2 +- .../supl/asn-rrlp/NavModel-KeplerianSet.c | 270 ++-- src/core/libs/supl/asn-rrlp/NavModelElement.c | 20 +- src/core/libs/supl/asn-rrlp/NavModelElement.h | 2 +- src/core/libs/supl/asn-rrlp/NavigationModel.c | 12 +- .../libs/supl/asn-rrlp/NeighborIdentity.c | 62 +- .../libs/supl/asn-rrlp/NeighborIdentity.h | 2 +- .../libs/supl/asn-rrlp/NumOfMeasurements.c | 66 +- src/core/libs/supl/asn-rrlp/OCTET_STRING.c | 1146 ++++++++--------- src/core/libs/supl/asn-rrlp/OCTET_STRING.h | 2 +- .../libs/supl/asn-rrlp/OTD-FirstSetMsrs.c | 62 +- .../supl/asn-rrlp/OTD-MeasureInfo-5-Ext.c | 56 +- .../supl/asn-rrlp/OTD-MeasureInfo-R98-Ext.c | 16 +- src/core/libs/supl/asn-rrlp/OTD-MeasureInfo.c | 22 +- src/core/libs/supl/asn-rrlp/OTD-Measurement.c | 30 +- src/core/libs/supl/asn-rrlp/OTD-Measurement.h | 2 +- .../supl/asn-rrlp/OTD-MeasurementWithID.c | 40 +- .../supl/asn-rrlp/OTD-MeasurementWithID.h | 4 +- .../asn-rrlp/OTD-MsrElementFirst-R98-Ext.c | 18 +- .../libs/supl/asn-rrlp/OTD-MsrElementFirst.c | 72 +- .../libs/supl/asn-rrlp/OTD-MsrElementFirst.h | 4 +- .../libs/supl/asn-rrlp/OTD-MsrElementRest.c | 74 +- .../libs/supl/asn-rrlp/OTD-MsrElementRest.h | 4 +- .../libs/supl/asn-rrlp/OTD-MsrsOfOtherSets.c | 26 +- src/core/libs/supl/asn-rrlp/OTDValue.c | 46 +- src/core/libs/supl/asn-rrlp/PDU.c | 24 +- src/core/libs/supl/asn-rrlp/PDU.h | 2 +- src/core/libs/supl/asn-rrlp/PositionData.c | 60 +- .../libs/supl/asn-rrlp/PositionInstruct.c | 54 +- .../libs/supl/asn-rrlp/PositionInstruct.h | 4 +- src/core/libs/supl/asn-rrlp/PositionMethod.c | 58 +- src/core/libs/supl/asn-rrlp/ProtocolError.c | 36 +- src/core/libs/supl/asn-rrlp/RRLP-Component.c | 48 +- src/core/libs/supl/asn-rrlp/RRLP-Component.h | 4 +- src/core/libs/supl/asn-rrlp/RefLocation.c | 10 +- src/core/libs/supl/asn-rrlp/RefQuality.c | 48 +- .../libs/supl/asn-rrlp/ReferenceAssistData.c | 40 +- .../libs/supl/asn-rrlp/ReferenceAssistData.h | 2 +- src/core/libs/supl/asn-rrlp/ReferenceFrame.c | 28 +- .../libs/supl/asn-rrlp/ReferenceIdentity.c | 12 +- .../supl/asn-rrlp/ReferenceIdentityType.c | 54 +- .../supl/asn-rrlp/ReferenceIdentityType.h | 2 +- .../libs/supl/asn-rrlp/ReferenceRelation.c | 62 +- src/core/libs/supl/asn-rrlp/ReferenceTime.c | 28 +- src/core/libs/supl/asn-rrlp/ReferenceTime.h | 2 +- src/core/libs/supl/asn-rrlp/ReferenceWGS84.c | 32 +- .../Rel-5-MsrPosition-Rsp-Extension.c | 48 +- .../asn-rrlp/Rel-5-ProtocolError-Extension.c | 20 +- .../Rel-7-MsrPosition-Rsp-Extension.c | 46 +- .../Rel-98-MsrPosition-Rsp-Extension.c | 50 +- .../asn-rrlp/Rel5-AssistanceData-Extension.c | 18 +- .../asn-rrlp/Rel5-MsrPosition-Req-Extension.c | 18 +- .../asn-rrlp/Rel7-AssistanceData-Extension.c | 48 +- .../asn-rrlp/Rel7-MsrPosition-Req-Extension.c | 88 +- .../asn-rrlp/Rel7-MsrPosition-Req-Extension.h | 2 +- .../asn-rrlp/Rel98-AssistanceData-Extension.c | 50 +- .../asn-rrlp/Rel98-AssistanceData-Extension.h | 2 +- .../libs/supl/asn-rrlp/Rel98-Ext-ExpOTD.c | 30 +- .../Rel98-MsrPosition-Req-Extension.c | 50 +- .../Rel98-MsrPosition-Req-Extension.h | 2 +- src/core/libs/supl/asn-rrlp/RelDistance.c | 56 +- src/core/libs/supl/asn-rrlp/RelativeAlt.c | 56 +- src/core/libs/supl/asn-rrlp/RequestIndex.c | 60 +- .../libs/supl/asn-rrlp/RequiredResponseTime.c | 52 +- src/core/libs/supl/asn-rrlp/RoughRTD.c | 46 +- src/core/libs/supl/asn-rrlp/SVID.c | 44 +- src/core/libs/supl/asn-rrlp/SVIDMASK.c | 46 +- src/core/libs/supl/asn-rrlp/SatElement.c | 112 +- src/core/libs/supl/asn-rrlp/SatStatus.c | 32 +- src/core/libs/supl/asn-rrlp/SatelliteID.c | 56 +- .../supl/asn-rrlp/SeqOf-BadSatelliteSet.c | 8 +- .../libs/supl/asn-rrlp/SeqOf-GANSSDataBits.c | 8 +- .../libs/supl/asn-rrlp/SeqOfAcquisElement.c | 8 +- .../libs/supl/asn-rrlp/SeqOfAlmanacElement.c | 8 +- .../supl/asn-rrlp/SeqOfBadSignalElement.c | 8 +- .../supl/asn-rrlp/SeqOfDGANSSSgnElement.c | 8 +- .../supl/asn-rrlp/SeqOfGANSS-MsrSetElement.c | 8 +- .../supl/asn-rrlp/SeqOfGANSS-SgnElement.c | 8 +- .../supl/asn-rrlp/SeqOfGANSS-SgnTypeElement.c | 8 +- .../supl/asn-rrlp/SeqOfGANSSAlmanacElement.c | 8 +- .../SeqOfGANSSGenericAssistDataElement.c | 10 +- .../SeqOfGANSSRefMeasurementElement.c | 10 +- .../asn-rrlp/SeqOfGANSSSatelliteElement.c | 10 +- .../libs/supl/asn-rrlp/SeqOfGANSSTimeModel.c | 8 +- .../libs/supl/asn-rrlp/SeqOfGPS-MsrElement.c | 8 +- .../supl/asn-rrlp/SeqOfGPS-MsrSetElement.c | 8 +- .../asn-rrlp/SeqOfMsrAssistBTS-R98-ExpOTD.c | 10 +- .../libs/supl/asn-rrlp/SeqOfMsrAssistBTS.c | 8 +- .../libs/supl/asn-rrlp/SeqOfNavModelElement.c | 8 +- .../asn-rrlp/SeqOfOTD-FirstSetMsrs-R98-Ext.c | 10 +- .../supl/asn-rrlp/SeqOfOTD-FirstSetMsrs.c | 8 +- .../supl/asn-rrlp/SeqOfOTD-MsrElementRest.c | 8 +- .../supl/asn-rrlp/SeqOfOTD-MsrsOfOtherSets.c | 8 +- .../asn-rrlp/SeqOfReferenceIdentityType.c | 10 +- src/core/libs/supl/asn-rrlp/SeqOfSatElement.c | 6 +- .../libs/supl/asn-rrlp/SeqOfSgnTypeElement.c | 8 +- .../asn-rrlp/SeqOfStandardClockModelElement.c | 10 +- .../SeqOfSystemInfoAssistBTS-R98-ExpOTD.c | 10 +- .../supl/asn-rrlp/SeqOfSystemInfoAssistBTS.c | 8 +- src/core/libs/supl/asn-rrlp/SgnTypeElement.c | 34 +- src/core/libs/supl/asn-rrlp/SgnTypeElement.h | 2 +- .../supl/asn-rrlp/StandardClockModelElement.c | 96 +- src/core/libs/supl/asn-rrlp/StdResolution.c | 60 +- .../asn-rrlp/SystemInfoAssistBTS-R98-ExpOTD.c | 22 +- .../asn-rrlp/SystemInfoAssistBTS-R98-ExpOTD.h | 2 +- .../libs/supl/asn-rrlp/SystemInfoAssistBTS.c | 18 +- .../libs/supl/asn-rrlp/SystemInfoAssistBTS.h | 2 +- .../SystemInfoAssistData-R98-ExpOTD.c | 20 +- .../libs/supl/asn-rrlp/SystemInfoAssistData.c | 16 +- src/core/libs/supl/asn-rrlp/SystemInfoIndex.c | 64 +- src/core/libs/supl/asn-rrlp/TA0.c | 46 +- src/core/libs/supl/asn-rrlp/TA1.c | 44 +- src/core/libs/supl/asn-rrlp/TA2.c | 44 +- src/core/libs/supl/asn-rrlp/TLMReservedBits.c | 64 +- src/core/libs/supl/asn-rrlp/TLMWord.c | 46 +- .../supl/asn-rrlp/TOA-MeasurementsOfRef.c | 22 +- .../supl/asn-rrlp/TOA-MeasurementsOfRef.h | 2 +- src/core/libs/supl/asn-rrlp/TimeRelation.c | 16 +- src/core/libs/supl/asn-rrlp/TimeSlot.c | 46 +- src/core/libs/supl/asn-rrlp/TimeSlotScheme.c | 58 +- src/core/libs/supl/asn-rrlp/UTCModel.c | 120 +- src/core/libs/supl/asn-rrlp/UlPseudoSegInd.c | 58 +- .../supl/asn-rrlp/UncompressedEphemeris.c | 558 ++++---- .../supl/asn-rrlp/UncompressedEphemeris.h | 2 +- src/core/libs/supl/asn-rrlp/UseMultipleSets.c | 60 +- .../libs/supl/asn-rrlp/VelocityEstimate.c | 62 +- src/core/libs/supl/asn-rrlp/asn_SEQUENCE_OF.c | 2 +- src/core/libs/supl/asn-rrlp/asn_SET_OF.c | 2 +- src/core/libs/supl/asn-rrlp/asn_application.h | 4 +- src/core/libs/supl/asn-rrlp/asn_codecs_prim.c | 126 +- src/core/libs/supl/asn-rrlp/asn_codecs_prim.h | 4 +- src/core/libs/supl/asn-rrlp/asn_internal.h | 7 +- src/core/libs/supl/asn-rrlp/asn_system.h | 10 +- src/core/libs/supl/asn-rrlp/ber_decoder.c | 56 +- src/core/libs/supl/asn-rrlp/ber_decoder.h | 4 +- src/core/libs/supl/asn-rrlp/ber_tlv_length.c | 6 +- src/core/libs/supl/asn-rrlp/ber_tlv_length.h | 4 +- src/core/libs/supl/asn-rrlp/ber_tlv_tag.c | 24 +- src/core/libs/supl/asn-rrlp/ber_tlv_tag.h | 2 +- src/core/libs/supl/asn-rrlp/constr_CHOICE.c | 716 +++++----- src/core/libs/supl/asn-rrlp/constr_SEQUENCE.c | 1016 +++++++-------- .../libs/supl/asn-rrlp/constr_SEQUENCE_OF.c | 28 +- src/core/libs/supl/asn-rrlp/constr_SET_OF.c | 426 +++--- src/core/libs/supl/asn-rrlp/constr_TYPE.c | 4 +- src/core/libs/supl/asn-rrlp/constr_TYPE.h | 38 +- src/core/libs/supl/asn-rrlp/constraints.c | 16 +- src/core/libs/supl/asn-rrlp/constraints.h | 4 +- .../libs/supl/asn-rrlp/converter-sample.c | 717 +++++------ src/core/libs/supl/asn-rrlp/der_encoder.c | 34 +- src/core/libs/supl/asn-rrlp/der_encoder.h | 20 +- src/core/libs/supl/asn-rrlp/per_decoder.c | 12 +- src/core/libs/supl/asn-rrlp/per_decoder.h | 16 +- src/core/libs/supl/asn-rrlp/per_encoder.c | 56 +- src/core/libs/supl/asn-rrlp/per_encoder.h | 2 +- src/core/libs/supl/asn-rrlp/per_opentype.c | 100 +- src/core/libs/supl/asn-rrlp/per_opentype.h | 10 +- src/core/libs/supl/asn-rrlp/per_support.c | 20 +- src/core/libs/supl/asn-rrlp/per_support.h | 14 +- src/core/libs/supl/asn-rrlp/xer_decoder.c | 220 ++-- src/core/libs/supl/asn-rrlp/xer_decoder.h | 10 +- src/core/libs/supl/asn-rrlp/xer_encoder.c | 6 +- src/core/libs/supl/asn-rrlp/xer_encoder.h | 10 +- src/core/libs/supl/asn-rrlp/xer_support.c | 274 ++-- src/core/libs/supl/asn-rrlp/xer_support.h | 6 +- src/core/libs/supl/asn-supl/.clang-format | 5 - src/core/libs/supl/asn-supl/AltitudeInfo.c | 54 +- src/core/libs/supl/asn-supl/BIT_STRING.c | 19 +- src/core/libs/supl/asn-supl/BOOLEAN.c | 92 +- src/core/libs/supl/asn-supl/CPICH-Ec-N0.c | 56 +- src/core/libs/supl/asn-supl/CPICH-RSCP.c | 48 +- .../libs/supl/asn-supl/CdmaCellInformation.c | 120 +- src/core/libs/supl/asn-supl/CellInfo.c | 30 +- src/core/libs/supl/asn-supl/CellInfo.h | 2 +- .../libs/supl/asn-supl/CellMeasuredResults.c | 144 +-- .../libs/supl/asn-supl/CellMeasuredResults.h | 10 +- .../supl/asn-supl/CellMeasuredResultsList.c | 8 +- .../libs/supl/asn-supl/CellParametersID.c | 64 +- src/core/libs/supl/asn-supl/DUMMY.c | 42 +- src/core/libs/supl/asn-supl/ENUMERATED.c | 12 +- src/core/libs/supl/asn-supl/EncodingType.c | 56 +- src/core/libs/supl/asn-supl/FQDN.c | 137 +- src/core/libs/supl/asn-supl/FormatIndicator.c | 60 +- src/core/libs/supl/asn-supl/FrequencyInfo.c | 32 +- .../libs/supl/asn-supl/FrequencyInfoFDD.c | 18 +- .../libs/supl/asn-supl/FrequencyInfoTDD.c | 10 +- src/core/libs/supl/asn-supl/GeneralizedTime.c | 244 ++-- src/core/libs/supl/asn-supl/GeneralizedTime.h | 16 +- .../libs/supl/asn-supl/GsmCellInformation.c | 80 +- src/core/libs/supl/asn-supl/Horandveruncert.c | 86 +- src/core/libs/supl/asn-supl/Horandvervel.c | 64 +- src/core/libs/supl/asn-supl/Horvel.c | 36 +- src/core/libs/supl/asn-supl/Horveluncert.c | 48 +- src/core/libs/supl/asn-supl/IA5String.c | 14 +- src/core/libs/supl/asn-supl/INTEGER.c | 522 ++++---- src/core/libs/supl/asn-supl/IPAddress.c | 32 +- src/core/libs/supl/asn-supl/KeyIdentity.c | 56 +- src/core/libs/supl/asn-supl/KeyIdentity4.c | 60 +- src/core/libs/supl/asn-supl/LocationId.c | 16 +- src/core/libs/supl/asn-supl/MAC.c | 44 +- src/core/libs/supl/asn-supl/MeasuredResults.c | 34 +- src/core/libs/supl/asn-supl/MeasuredResults.h | 2 +- .../libs/supl/asn-supl/MeasuredResultsList.c | 8 +- src/core/libs/supl/asn-supl/NMR.c | 8 +- src/core/libs/supl/asn-supl/NMRelement.c | 42 +- .../libs/supl/asn-supl/NativeEnumerated.c | 26 +- src/core/libs/supl/asn-supl/NativeInteger.c | 54 +- src/core/libs/supl/asn-supl/NativeInteger.h | 2 +- src/core/libs/supl/asn-supl/Notification.c | 72 +- src/core/libs/supl/asn-supl/Notification.h | 4 +- .../libs/supl/asn-supl/NotificationType.c | 60 +- src/core/libs/supl/asn-supl/OCTET_STRING.c | 1146 ++++++++--------- src/core/libs/supl/asn-supl/OCTET_STRING.h | 2 +- src/core/libs/supl/asn-supl/Pathloss.c | 46 +- src/core/libs/supl/asn-supl/PosMethod.c | 42 +- src/core/libs/supl/asn-supl/PosPayLoad.c | 42 +- src/core/libs/supl/asn-supl/PosProtocol.c | 24 +- src/core/libs/supl/asn-supl/PosTechnology.c | 58 +- src/core/libs/supl/asn-supl/Position.c | 26 +- src/core/libs/supl/asn-supl/Position.h | 2 +- .../libs/supl/asn-supl/PositionEstimate.c | 166 +-- src/core/libs/supl/asn-supl/PrefMethod.c | 44 +- .../libs/supl/asn-supl/PrimaryCCPCH-RSCP.c | 66 +- .../libs/supl/asn-supl/PrimaryCPICH-Info.c | 16 +- src/core/libs/supl/asn-supl/QoP.c | 62 +- .../libs/supl/asn-supl/RequestedAssistData.c | 114 +- src/core/libs/supl/asn-supl/SETAuthKey.c | 32 +- src/core/libs/supl/asn-supl/SETCapabilities.c | 30 +- src/core/libs/supl/asn-supl/SETCapabilities.h | 2 +- src/core/libs/supl/asn-supl/SETId.c | 78 +- src/core/libs/supl/asn-supl/SETId.h | 4 +- src/core/libs/supl/asn-supl/SLPAddress.c | 16 +- src/core/libs/supl/asn-supl/SLPAddress.h | 2 +- src/core/libs/supl/asn-supl/SLPMode.c | 42 +- src/core/libs/supl/asn-supl/SUPLEND.c | 28 +- src/core/libs/supl/asn-supl/SUPLINIT.c | 60 +- src/core/libs/supl/asn-supl/SUPLINIT.h | 6 +- src/core/libs/supl/asn-supl/SUPLPOS.c | 20 +- src/core/libs/supl/asn-supl/SUPLPOSINIT.c | 54 +- src/core/libs/supl/asn-supl/SUPLPOSINIT.h | 4 +- src/core/libs/supl/asn-supl/SUPLRESPONSE.c | 34 +- src/core/libs/supl/asn-supl/SUPLRESPONSE.h | 4 +- src/core/libs/supl/asn-supl/SUPLSTART.c | 26 +- src/core/libs/supl/asn-supl/SUPLSTART.h | 2 +- src/core/libs/supl/asn-supl/SatelliteInfo.c | 8 +- .../libs/supl/asn-supl/SatelliteInfoElement.c | 30 +- src/core/libs/supl/asn-supl/SessionID.c | 20 +- src/core/libs/supl/asn-supl/SetSessionID.c | 24 +- src/core/libs/supl/asn-supl/SetSessionID.h | 2 +- src/core/libs/supl/asn-supl/SlpSessionID.c | 24 +- src/core/libs/supl/asn-supl/SlpSessionID.h | 2 +- src/core/libs/supl/asn-supl/Status.c | 40 +- src/core/libs/supl/asn-supl/StatusCode.c | 44 +- src/core/libs/supl/asn-supl/TGSN.c | 44 +- .../libs/supl/asn-supl/TimeslotISCP-List.c | 8 +- src/core/libs/supl/asn-supl/TimeslotISCP.c | 60 +- src/core/libs/supl/asn-supl/UARFCN.c | 44 +- src/core/libs/supl/asn-supl/ULP-PDU.c | 42 +- src/core/libs/supl/asn-supl/ULP-PDU.h | 4 +- src/core/libs/supl/asn-supl/UTCTime.c | 26 +- src/core/libs/supl/asn-supl/UTCTime.h | 2 +- .../libs/supl/asn-supl/UTRA-CarrierRSSI.c | 64 +- src/core/libs/supl/asn-supl/UlpMessage.c | 68 +- src/core/libs/supl/asn-supl/UlpMessage.h | 12 +- src/core/libs/supl/asn-supl/Velocity.c | 38 +- src/core/libs/supl/asn-supl/Velocity.h | 6 +- src/core/libs/supl/asn-supl/Ver.c | 44 +- src/core/libs/supl/asn-supl/Version.c | 48 +- src/core/libs/supl/asn-supl/VisibleString.c | 16 +- .../libs/supl/asn-supl/WcdmaCellInformation.c | 82 +- .../libs/supl/asn-supl/XNavigationModel.c | 72 +- src/core/libs/supl/asn-supl/asn_SEQUENCE_OF.c | 2 +- src/core/libs/supl/asn-supl/asn_SET_OF.c | 2 +- src/core/libs/supl/asn-supl/asn_application.h | 4 +- src/core/libs/supl/asn-supl/asn_codecs_prim.c | 126 +- src/core/libs/supl/asn-supl/asn_codecs_prim.h | 4 +- src/core/libs/supl/asn-supl/asn_internal.h | 7 +- src/core/libs/supl/asn-supl/asn_system.h | 10 +- src/core/libs/supl/asn-supl/ber_decoder.c | 56 +- src/core/libs/supl/asn-supl/ber_decoder.h | 4 +- src/core/libs/supl/asn-supl/ber_tlv_length.c | 6 +- src/core/libs/supl/asn-supl/ber_tlv_length.h | 4 +- src/core/libs/supl/asn-supl/ber_tlv_tag.c | 24 +- src/core/libs/supl/asn-supl/ber_tlv_tag.h | 2 +- src/core/libs/supl/asn-supl/constr_CHOICE.c | 716 +++++----- src/core/libs/supl/asn-supl/constr_SEQUENCE.c | 1016 +++++++-------- .../libs/supl/asn-supl/constr_SEQUENCE_OF.c | 28 +- src/core/libs/supl/asn-supl/constr_SET_OF.c | 426 +++--- src/core/libs/supl/asn-supl/constr_TYPE.c | 4 +- src/core/libs/supl/asn-supl/constr_TYPE.h | 38 +- src/core/libs/supl/asn-supl/constraints.c | 16 +- src/core/libs/supl/asn-supl/constraints.h | 4 +- src/core/libs/supl/asn-supl/der_encoder.c | 34 +- src/core/libs/supl/asn-supl/der_encoder.h | 20 +- src/core/libs/supl/asn-supl/per_decoder.c | 12 +- src/core/libs/supl/asn-supl/per_decoder.h | 16 +- src/core/libs/supl/asn-supl/per_encoder.c | 56 +- src/core/libs/supl/asn-supl/per_encoder.h | 2 +- src/core/libs/supl/asn-supl/per_opentype.c | 100 +- src/core/libs/supl/asn-supl/per_opentype.h | 10 +- src/core/libs/supl/asn-supl/per_support.c | 20 +- src/core/libs/supl/asn-supl/per_support.h | 12 +- src/core/libs/supl/asn-supl/xer_decoder.c | 220 ++-- src/core/libs/supl/asn-supl/xer_decoder.h | 10 +- src/core/libs/supl/asn-supl/xer_encoder.c | 6 +- src/core/libs/supl/asn-supl/xer_encoder.h | 10 +- src/core/libs/supl/asn-supl/xer_support.c | 274 ++-- src/core/libs/supl/asn-supl/xer_support.h | 6 +- src/core/libs/supl/supl.c | 2 +- 470 files changed, 12552 insertions(+), 12480 deletions(-) delete mode 100644 src/core/libs/supl/asn-rrlp/.clang-format delete mode 100644 src/core/libs/supl/asn-supl/.clang-format diff --git a/src/algorithms/libs/volk_gnsssdr_module/volk_gnsssdr/lib/volk_gnsssdr_malloc.c b/src/algorithms/libs/volk_gnsssdr_module/volk_gnsssdr/lib/volk_gnsssdr_malloc.c index 091626dfc..812fe99ce 100644 --- a/src/algorithms/libs/volk_gnsssdr_module/volk_gnsssdr/lib/volk_gnsssdr_malloc.c +++ b/src/algorithms/libs/volk_gnsssdr_module/volk_gnsssdr/lib/volk_gnsssdr_malloc.c @@ -18,8 +18,8 @@ */ #include "volk_gnsssdr/volk_gnsssdr_malloc.h" -#include #include +#include #include /* diff --git a/src/algorithms/libs/volk_gnsssdr_module/volk_gnsssdr/lib/volk_gnsssdr_rank_archs.c b/src/algorithms/libs/volk_gnsssdr_module/volk_gnsssdr/lib/volk_gnsssdr_rank_archs.c index abfb42e54..6e5102b81 100644 --- a/src/algorithms/libs/volk_gnsssdr_module/volk_gnsssdr/lib/volk_gnsssdr_rank_archs.c +++ b/src/algorithms/libs/volk_gnsssdr_module/volk_gnsssdr/lib/volk_gnsssdr_rank_archs.c @@ -16,12 +16,13 @@ * along with GNSS-SDR. If not, see . */ - +// clang-format off #include #include #include #include #include +// clang-format on #if __GNUC__ > 3 || __GNUC__ == 3 && __GNUC_MINOR__ >= 4 #define __popcnt __builtin_popcount diff --git a/src/algorithms/libs/volk_gnsssdr_module/volk_gnsssdr/tmpl/volk_gnsssdr.tmpl.c b/src/algorithms/libs/volk_gnsssdr_module/volk_gnsssdr/tmpl/volk_gnsssdr.tmpl.c index ac7c53a0e..ebb14a8b4 100644 --- a/src/algorithms/libs/volk_gnsssdr_module/volk_gnsssdr/tmpl/volk_gnsssdr.tmpl.c +++ b/src/algorithms/libs/volk_gnsssdr_module/volk_gnsssdr/tmpl/volk_gnsssdr.tmpl.c @@ -16,15 +16,17 @@ * along with GNSS-SDR. If not, see . */ +// clang-format off #include #include "volk_gnsssdr_machines.h" #include #include #include "volk_gnsssdr_rank_archs.h" #include +#include #include #include -#include +// clang-format on static size_t __alignment = 0; static intptr_t __alignment_mask = 0; diff --git a/src/algorithms/libs/volk_gnsssdr_module/volk_gnsssdr/tmpl/volk_gnsssdr_cpu.tmpl.c b/src/algorithms/libs/volk_gnsssdr_module/volk_gnsssdr/tmpl/volk_gnsssdr_cpu.tmpl.c index 8c0e74b1b..808013fd5 100644 --- a/src/algorithms/libs/volk_gnsssdr_module/volk_gnsssdr/tmpl/volk_gnsssdr_cpu.tmpl.c +++ b/src/algorithms/libs/volk_gnsssdr_module/volk_gnsssdr/tmpl/volk_gnsssdr_cpu.tmpl.c @@ -16,10 +16,12 @@ * along with GNSS-SDR. If not, see . */ +// clang-format off #include #include #include #include +// clang-format on struct VOLK_CPU volk_gnsssdr_cpu; diff --git a/src/algorithms/libs/volk_gnsssdr_module/volk_gnsssdr/tmpl/volk_gnsssdr_machines.tmpl.c b/src/algorithms/libs/volk_gnsssdr_module/volk_gnsssdr/tmpl/volk_gnsssdr_machines.tmpl.c index 40869bf01..295ccdbfe 100644 --- a/src/algorithms/libs/volk_gnsssdr_module/volk_gnsssdr/tmpl/volk_gnsssdr_machines.tmpl.c +++ b/src/algorithms/libs/volk_gnsssdr_module/volk_gnsssdr/tmpl/volk_gnsssdr_machines.tmpl.c @@ -16,11 +16,11 @@ * along with GNSS-SDR. If not, see . */ +// clang-format off #include #include #include "volk_gnsssdr_machines.h" -// clang-format off struct volk_gnsssdr_machine *volk_gnsssdr_machines[] = { %for machine in machines: #ifdef LV_MACHINE_${machine.name.upper()} diff --git a/src/algorithms/telemetry_decoder/libs/libswiftcnav/cnav_msg.c b/src/algorithms/telemetry_decoder/libs/libswiftcnav/cnav_msg.c index 271fc6504..83bd34148 100644 --- a/src/algorithms/telemetry_decoder/libs/libswiftcnav/cnav_msg.c +++ b/src/algorithms/telemetry_decoder/libs/libswiftcnav/cnav_msg.c @@ -30,10 +30,9 @@ */ -#include "edc.h" -#include "bits.h" #include "cnav_msg.h" - +#include "bits.h" +#include "edc.h" #include #include diff --git a/src/core/libs/supl/asn-rrlp/.clang-format b/src/core/libs/supl/asn-rrlp/.clang-format deleted file mode 100644 index 15e78fedf..000000000 --- a/src/core/libs/supl/asn-rrlp/.clang-format +++ /dev/null @@ -1,5 +0,0 @@ ---- -Language: Cpp -DisableFormat: true -... - diff --git a/src/core/libs/supl/asn-rrlp/Accuracy.c b/src/core/libs/supl/asn-rrlp/Accuracy.c index a5803c9cf..911b6047d 100644 --- a/src/core/libs/supl/asn-rrlp/Accuracy.c +++ b/src/core/libs/supl/asn-rrlp/Accuracy.c @@ -7,14 +7,14 @@ #include "Accuracy.h" int Accuracy_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int Accuracy_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -55,68 +55,68 @@ static void Accuracy_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void Accuracy_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { Accuracy_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int Accuracy_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { Accuracy_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t Accuracy_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, + int tag_mode) { Accuracy_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t Accuracy_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { Accuracy_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t Accuracy_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { Accuracy_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t Accuracy_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { Accuracy_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t Accuracy_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { Accuracy_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t Accuracy_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { Accuracy_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/AccuracyOpt.c b/src/core/libs/supl/asn-rrlp/AccuracyOpt.c index 835ac4ee4..fa97ee7b6 100644 --- a/src/core/libs/supl/asn-rrlp/AccuracyOpt.c +++ b/src/core/libs/supl/asn-rrlp/AccuracyOpt.c @@ -8,10 +8,10 @@ static asn_TYPE_member_t asn_MBR_AccuracyOpt_1[] = { {ATF_POINTER, 1, offsetof(struct AccuracyOpt, accuracy), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Accuracy, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "accuracy"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Accuracy, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "accuracy"}, }; static int asn_MAP_AccuracyOpt_oms_1[] = {0}; static ber_tlv_tag_t asn_DEF_AccuracyOpt_tags_1[] = { diff --git a/src/core/libs/supl/asn-rrlp/AcquisAssist.c b/src/core/libs/supl/asn-rrlp/AcquisAssist.c index 4a15050d4..668cd7679 100644 --- a/src/core/libs/supl/asn-rrlp/AcquisAssist.c +++ b/src/core/libs/supl/asn-rrlp/AcquisAssist.c @@ -8,17 +8,17 @@ static asn_TYPE_member_t asn_MBR_AcquisAssist_1[] = { {ATF_NOFLAGS, 0, offsetof(struct AcquisAssist, timeRelation), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_TimeRelation, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "timeRelation"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_TimeRelation, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "timeRelation"}, {ATF_NOFLAGS, 0, offsetof(struct AcquisAssist, acquisList), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfAcquisElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "acquisList"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfAcquisElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "acquisList"}, }; static ber_tlv_tag_t asn_DEF_AcquisAssist_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/AcquisAssist.h b/src/core/libs/supl/asn-rrlp/AcquisAssist.h index 251311623..59fad8efd 100644 --- a/src/core/libs/supl/asn-rrlp/AcquisAssist.h +++ b/src/core/libs/supl/asn-rrlp/AcquisAssist.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include "TimeRelation.h" #include "SeqOfAcquisElement.h" +#include "TimeRelation.h" #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/AcquisElement.c b/src/core/libs/supl/asn-rrlp/AcquisElement.c index 3182bab4f..044f7cf9d 100644 --- a/src/core/libs/supl/asn-rrlp/AcquisElement.c +++ b/src/core/libs/supl/asn-rrlp/AcquisElement.c @@ -7,16 +7,16 @@ #include "AcquisElement.h" static int memb_doppler0_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,22 +30,22 @@ static int memb_doppler0_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_codePhase_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -59,22 +59,22 @@ static int memb_codePhase_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_intCodePhase_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -88,22 +88,22 @@ static int memb_intCodePhase_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_gpsBitNumber_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -117,7 +117,7 @@ static int memb_gpsBitNumber_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -131,7 +131,7 @@ static int memb_codePhaseSearchWindow_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -145,7 +145,7 @@ static int memb_codePhaseSearchWindow_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -182,44 +182,44 @@ static asn_per_constraints_t ASN_PER_MEMB_CODE_PHASE_SEARCH_WINDOW_CONSTR_8 = { }; static asn_TYPE_member_t asn_MBR_AcquisElement_1[] = { {ATF_NOFLAGS, 0, offsetof(struct AcquisElement, svid), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SatelliteID, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "svid"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SatelliteID, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "svid"}, {ATF_NOFLAGS, 0, offsetof(struct AcquisElement, doppler0), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_doppler0_constraint_1, - &ASN_PER_MEMB_DOPPLER0_CONSTR_3, 0, "doppler0"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_doppler0_constraint_1, + &ASN_PER_MEMB_DOPPLER0_CONSTR_3, 0, "doppler0"}, {ATF_POINTER, 1, offsetof(struct AcquisElement, addionalDoppler), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_AddionalDopplerFields, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "addionalDoppler"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_AddionalDopplerFields, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "addionalDoppler"}, {ATF_NOFLAGS, 0, offsetof(struct AcquisElement, codePhase), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_codePhase_constraint_1, - &ASN_PER_MEMB_CODE_PHASE_CONSTR_5, 0, "codePhase"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_codePhase_constraint_1, + &ASN_PER_MEMB_CODE_PHASE_CONSTR_5, 0, "codePhase"}, {ATF_NOFLAGS, 0, offsetof(struct AcquisElement, intCodePhase), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_intCodePhase_constraint_1, - &ASN_PER_MEMB_INT_CODE_PHASE_CONSTR_6, 0, "intCodePhase"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_intCodePhase_constraint_1, + &ASN_PER_MEMB_INT_CODE_PHASE_CONSTR_6, 0, "intCodePhase"}, {ATF_NOFLAGS, 0, offsetof(struct AcquisElement, gpsBitNumber), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_gpsBitNumber_constraint_1, - &ASN_PER_MEMB_GPS_BIT_NUMBER_CONSTR_7, 0, "gpsBitNumber"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_gpsBitNumber_constraint_1, + &ASN_PER_MEMB_GPS_BIT_NUMBER_CONSTR_7, 0, "gpsBitNumber"}, {ATF_NOFLAGS, 0, offsetof(struct AcquisElement, codePhaseSearchWindow), - (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_codePhaseSearchWindow_constraint_1, - &ASN_PER_MEMB_CODE_PHASE_SEARCH_WINDOW_CONSTR_8, 0, - "codePhaseSearchWindow"}, + (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_codePhaseSearchWindow_constraint_1, + &ASN_PER_MEMB_CODE_PHASE_SEARCH_WINDOW_CONSTR_8, 0, + "codePhaseSearchWindow"}, {ATF_POINTER, 1, offsetof(struct AcquisElement, addionalAngle), - (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_AddionalAngleFields, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "addionalAngle"}, + (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_AddionalAngleFields, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "addionalAngle"}, }; static int asn_MAP_AcquisElement_oms_1[] = {2, 7}; static ber_tlv_tag_t asn_DEF_AcquisElement_tags_1[] = { @@ -232,7 +232,7 @@ static asn_TYPE_tag2member_t asn_MAP_AcquisElement_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, 0}, /* intCodePhase at 841 */ {(ASN_TAG_CLASS_CONTEXT | (5 << 2)), 5, 0, 0}, /* gpsBitNumber at 842 */ {(ASN_TAG_CLASS_CONTEXT | (6 << 2)), 6, 0, - 0}, /* codePhaseSearchWindow at 843 */ + 0}, /* codePhaseSearchWindow at 843 */ {(ASN_TAG_CLASS_CONTEXT | (7 << 2)), 7, 0, 0} /* addionalAngle at 844 */ }; static asn_SEQUENCE_specifics_t asn_SPC_AcquisElement_specs_1 = { @@ -265,7 +265,7 @@ asn_TYPE_descriptor_t asn_DEF_AcquisElement = { asn_DEF_AcquisElement_tags_1, /* Same as above */ sizeof(asn_DEF_AcquisElement_tags_1) / sizeof(asn_DEF_AcquisElement_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_AcquisElement_1, 8, /* Elements count */ &asn_SPC_AcquisElement_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/AcquisElement.h b/src/core/libs/supl/asn-rrlp/AcquisElement.h index 2c0802968..e9070a1f6 100644 --- a/src/core/libs/supl/asn-rrlp/AcquisElement.h +++ b/src/core/libs/supl/asn-rrlp/AcquisElement.h @@ -47,8 +47,8 @@ extern "C" #endif /* Referred external types */ -#include "AddionalDopplerFields.h" #include "AddionalAngleFields.h" +#include "AddionalDopplerFields.h" #endif /* _AcquisElement_H_ */ #include diff --git a/src/core/libs/supl/asn-rrlp/AddionalAngleFields.c b/src/core/libs/supl/asn-rrlp/AddionalAngleFields.c index 244a67cf6..d95e61684 100644 --- a/src/core/libs/supl/asn-rrlp/AddionalAngleFields.c +++ b/src/core/libs/supl/asn-rrlp/AddionalAngleFields.c @@ -7,16 +7,16 @@ #include "AddionalAngleFields.h" static int memb_azimuth_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,22 +30,22 @@ static int memb_azimuth_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_elevation_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -59,7 +59,7 @@ static int memb_elevation_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -78,13 +78,13 @@ static asn_per_constraints_t ASN_PER_MEMB_ELEVATION_CONSTR_3 = { }; static asn_TYPE_member_t asn_MBR_AddionalAngleFields_1[] = { {ATF_NOFLAGS, 0, offsetof(struct AddionalAngleFields, azimuth), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_azimuth_constraint_1, - &ASN_PER_MEMB_AZIMUTH_CONSTR_2, 0, "azimuth"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_azimuth_constraint_1, + &ASN_PER_MEMB_AZIMUTH_CONSTR_2, 0, "azimuth"}, {ATF_NOFLAGS, 0, offsetof(struct AddionalAngleFields, elevation), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_elevation_constraint_1, - &ASN_PER_MEMB_ELEVATION_CONSTR_3, 0, "elevation"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_elevation_constraint_1, + &ASN_PER_MEMB_ELEVATION_CONSTR_3, 0, "elevation"}, }; static ber_tlv_tag_t asn_DEF_AddionalAngleFields_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -122,7 +122,7 @@ asn_TYPE_descriptor_t asn_DEF_AddionalAngleFields = { asn_DEF_AddionalAngleFields_tags_1, /* Same as above */ sizeof(asn_DEF_AddionalAngleFields_tags_1) / sizeof(asn_DEF_AddionalAngleFields_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_AddionalAngleFields_1, 2, /* Elements count */ &asn_SPC_AddionalAngleFields_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/AddionalDopplerFields.c b/src/core/libs/supl/asn-rrlp/AddionalDopplerFields.c index c0963e5ec..423fa3bb5 100644 --- a/src/core/libs/supl/asn-rrlp/AddionalDopplerFields.c +++ b/src/core/libs/supl/asn-rrlp/AddionalDopplerFields.c @@ -7,16 +7,16 @@ #include "AddionalDopplerFields.h" static int memb_doppler1_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,7 +30,7 @@ static int memb_doppler1_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -44,7 +44,7 @@ static int memb_dopplerUncertainty_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -58,7 +58,7 @@ static int memb_dopplerUncertainty_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -77,20 +77,20 @@ static asn_per_constraints_t ASN_PER_MEMB_DOPPLER_UNCERTAINTY_CONSTR_3 = { }; static asn_TYPE_member_t asn_MBR_AddionalDopplerFields_1[] = { {ATF_NOFLAGS, 0, offsetof(struct AddionalDopplerFields, doppler1), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_doppler1_constraint_1, - &ASN_PER_MEMB_DOPPLER1_CONSTR_2, 0, "doppler1"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_doppler1_constraint_1, + &ASN_PER_MEMB_DOPPLER1_CONSTR_2, 0, "doppler1"}, {ATF_NOFLAGS, 0, offsetof(struct AddionalDopplerFields, dopplerUncertainty), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_dopplerUncertainty_constraint_1, - &ASN_PER_MEMB_DOPPLER_UNCERTAINTY_CONSTR_3, 0, "dopplerUncertainty"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_dopplerUncertainty_constraint_1, + &ASN_PER_MEMB_DOPPLER_UNCERTAINTY_CONSTR_3, 0, "dopplerUncertainty"}, }; static ber_tlv_tag_t asn_DEF_AddionalDopplerFields_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_AddionalDopplerFields_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* doppler1 at 850 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0} /* dopplerUncertainty at 851 */ + 0} /* dopplerUncertainty at 851 */ }; static asn_SEQUENCE_specifics_t asn_SPC_AddionalDopplerFields_specs_1 = { sizeof(struct AddionalDopplerFields), @@ -122,7 +122,7 @@ asn_TYPE_descriptor_t asn_DEF_AddionalDopplerFields = { asn_DEF_AddionalDopplerFields_tags_1, /* Same as above */ sizeof(asn_DEF_AddionalDopplerFields_tags_1) / sizeof(asn_DEF_AddionalDopplerFields_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_AddionalDopplerFields_1, 2, /* Elements count */ &asn_SPC_AddionalDopplerFields_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/AdditionalAssistanceData.c b/src/core/libs/supl/asn-rrlp/AdditionalAssistanceData.c index 40b13d653..72da77c30 100644 --- a/src/core/libs/supl/asn-rrlp/AdditionalAssistanceData.c +++ b/src/core/libs/supl/asn-rrlp/AdditionalAssistanceData.c @@ -8,37 +8,37 @@ static asn_TYPE_member_t asn_MBR_AdditionalAssistanceData_1[] = { {ATF_POINTER, 3, - offsetof(struct AdditionalAssistanceData, gpsAssistanceData), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GPSAssistanceData, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "gpsAssistanceData"}, + offsetof(struct AdditionalAssistanceData, gpsAssistanceData), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GPSAssistanceData, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "gpsAssistanceData"}, {ATF_POINTER, 2, - offsetof(struct AdditionalAssistanceData, extensionContainer), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_ExtensionContainer, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "extensionContainer"}, + offsetof(struct AdditionalAssistanceData, extensionContainer), + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_ExtensionContainer, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "extensionContainer"}, {ATF_POINTER, 1, - offsetof(struct AdditionalAssistanceData, ganssAssistanceData), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSAssistanceData, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssAssistanceData"}, + offsetof(struct AdditionalAssistanceData, ganssAssistanceData), + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSAssistanceData, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssAssistanceData"}, }; static int asn_MAP_AdditionalAssistanceData_oms_1[] = {0, 1, 2}; static ber_tlv_tag_t asn_DEF_AdditionalAssistanceData_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_AdditionalAssistanceData_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0}, /* gpsAssistanceData at 520 */ + 0}, /* gpsAssistanceData at 520 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0}, /* extensionContainer at 521 */ + 0}, /* extensionContainer at 521 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, - 0} /* ganssAssistanceData at 523 */ + 0} /* ganssAssistanceData at 523 */ }; static asn_SEQUENCE_specifics_t asn_SPC_AdditionalAssistanceData_specs_1 = { sizeof(struct AdditionalAssistanceData), @@ -70,7 +70,7 @@ asn_TYPE_descriptor_t asn_DEF_AdditionalAssistanceData = { asn_DEF_AdditionalAssistanceData_tags_1, /* Same as above */ sizeof(asn_DEF_AdditionalAssistanceData_tags_1) / sizeof(asn_DEF_AdditionalAssistanceData_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_AdditionalAssistanceData_1, 3, /* Elements count */ &asn_SPC_AdditionalAssistanceData_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/AdditionalAssistanceData.h b/src/core/libs/supl/asn-rrlp/AdditionalAssistanceData.h index bd36e1715..3ad5b6a0b 100644 --- a/src/core/libs/supl/asn-rrlp/AdditionalAssistanceData.h +++ b/src/core/libs/supl/asn-rrlp/AdditionalAssistanceData.h @@ -10,9 +10,9 @@ #include /* Including external dependencies */ -#include "GPSAssistanceData.h" #include "ExtensionContainer.h" #include "GANSSAssistanceData.h" +#include "GPSAssistanceData.h" #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/AdditionalDopplerFields.c b/src/core/libs/supl/asn-rrlp/AdditionalDopplerFields.c index ff66c2f3f..fa41ddedb 100644 --- a/src/core/libs/supl/asn-rrlp/AdditionalDopplerFields.c +++ b/src/core/libs/supl/asn-rrlp/AdditionalDopplerFields.c @@ -7,16 +7,16 @@ #include "AdditionalDopplerFields.h" static int memb_doppler1_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,7 +30,7 @@ static int memb_doppler1_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -44,7 +44,7 @@ static int memb_dopplerUncertainty_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -58,7 +58,7 @@ static int memb_dopplerUncertainty_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -77,21 +77,21 @@ static asn_per_constraints_t ASN_PER_MEMB_DOPPLER_UNCERTAINTY_CONSTR_3 = { }; static asn_TYPE_member_t asn_MBR_AdditionalDopplerFields_1[] = { {ATF_NOFLAGS, 0, offsetof(struct AdditionalDopplerFields, doppler1), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_doppler1_constraint_1, - &ASN_PER_MEMB_DOPPLER1_CONSTR_2, 0, "doppler1"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_doppler1_constraint_1, + &ASN_PER_MEMB_DOPPLER1_CONSTR_2, 0, "doppler1"}, {ATF_NOFLAGS, 0, - offsetof(struct AdditionalDopplerFields, dopplerUncertainty), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_dopplerUncertainty_constraint_1, - &ASN_PER_MEMB_DOPPLER_UNCERTAINTY_CONSTR_3, 0, "dopplerUncertainty"}, + offsetof(struct AdditionalDopplerFields, dopplerUncertainty), + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_dopplerUncertainty_constraint_1, + &ASN_PER_MEMB_DOPPLER_UNCERTAINTY_CONSTR_3, 0, "dopplerUncertainty"}, }; static ber_tlv_tag_t asn_DEF_AdditionalDopplerFields_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_AdditionalDopplerFields_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* doppler1 at 1342 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0} /* dopplerUncertainty at 1343 */ + 0} /* dopplerUncertainty at 1343 */ }; static asn_SEQUENCE_specifics_t asn_SPC_AdditionalDopplerFields_specs_1 = { sizeof(struct AdditionalDopplerFields), @@ -123,7 +123,7 @@ asn_TYPE_descriptor_t asn_DEF_AdditionalDopplerFields = { asn_DEF_AdditionalDopplerFields_tags_1, /* Same as above */ sizeof(asn_DEF_AdditionalDopplerFields_tags_1) / sizeof(asn_DEF_AdditionalDopplerFields_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_AdditionalDopplerFields_1, 2, /* Elements count */ &asn_SPC_AdditionalDopplerFields_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/AlertFlag.c b/src/core/libs/supl/asn-rrlp/AlertFlag.c index 23699b027..66d59832f 100644 --- a/src/core/libs/supl/asn-rrlp/AlertFlag.c +++ b/src/core/libs/supl/asn-rrlp/AlertFlag.c @@ -7,14 +7,14 @@ #include "AlertFlag.h" int AlertFlag_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int AlertFlag_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -55,68 +55,68 @@ static void AlertFlag_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void AlertFlag_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { AlertFlag_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int AlertFlag_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { AlertFlag_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t AlertFlag_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, + int tag_mode) { AlertFlag_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t AlertFlag_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { AlertFlag_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t AlertFlag_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { AlertFlag_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t AlertFlag_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { AlertFlag_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t AlertFlag_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { AlertFlag_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t AlertFlag_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { AlertFlag_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/Almanac-KeplerianSet.c b/src/core/libs/supl/asn-rrlp/Almanac-KeplerianSet.c index 1135c6ca3..a8ff33b4f 100644 --- a/src/core/libs/supl/asn-rrlp/Almanac-KeplerianSet.c +++ b/src/core/libs/supl/asn-rrlp/Almanac-KeplerianSet.c @@ -7,16 +7,16 @@ #include "Almanac-KeplerianSet.h" static int memb_kepAlmanacE_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,7 +30,7 @@ static int memb_kepAlmanacE_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -44,7 +44,7 @@ static int memb_kepAlmanacDeltaI_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -58,7 +58,7 @@ static int memb_kepAlmanacDeltaI_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -72,7 +72,7 @@ static int memb_kepAlmanacOmegaDot_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -86,22 +86,22 @@ static int memb_kepAlmanacOmegaDot_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_kepSVHealth_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -115,7 +115,7 @@ static int memb_kepSVHealth_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -129,7 +129,7 @@ static int memb_kepAlmanacAPowerHalf_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -143,7 +143,7 @@ static int memb_kepAlmanacAPowerHalf_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -157,7 +157,7 @@ static int memb_kepAlmanacOmega0_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -171,22 +171,22 @@ static int memb_kepAlmanacOmega0_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_kepAlmanacW_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -200,22 +200,22 @@ static int memb_kepAlmanacW_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_kepAlmanacM0_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -229,7 +229,7 @@ static int memb_kepAlmanacM0_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -243,7 +243,7 @@ static int memb_kepAlmanacAF0_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -257,7 +257,7 @@ static int memb_kepAlmanacAF0_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -271,7 +271,7 @@ static int memb_kepAlmanacAF1_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -285,7 +285,7 @@ static int memb_kepAlmanacAF1_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -352,61 +352,61 @@ static asn_per_constraints_t ASN_PER_MEMB_KEP_ALMANAC_A_F1_CONSTR_11 = { }; static asn_TYPE_member_t asn_MBR_Almanac_KeplerianSet_1[] = { {ATF_NOFLAGS, 0, offsetof(struct Almanac_KeplerianSet, kepAlmanacE), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_kepAlmanacE_constraint_1, - &ASN_PER_MEMB_KEP_ALMANAC_E_CONSTR_2, 0, "kepAlmanacE"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_kepAlmanacE_constraint_1, + &ASN_PER_MEMB_KEP_ALMANAC_E_CONSTR_2, 0, "kepAlmanacE"}, {ATF_NOFLAGS, 0, offsetof(struct Almanac_KeplerianSet, kepAlmanacDeltaI), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_kepAlmanacDeltaI_constraint_1, - &ASN_PER_MEMB_KEP_ALMANAC_DELTA_I_CONSTR_3, 0, "kepAlmanacDeltaI"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_kepAlmanacDeltaI_constraint_1, + &ASN_PER_MEMB_KEP_ALMANAC_DELTA_I_CONSTR_3, 0, "kepAlmanacDeltaI"}, {ATF_NOFLAGS, 0, offsetof(struct Almanac_KeplerianSet, kepAlmanacOmegaDot), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_kepAlmanacOmegaDot_constraint_1, - &ASN_PER_MEMB_KEP_ALMANAC_OMEGA_DOT_CONSTR_4, 0, "kepAlmanacOmegaDot"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_kepAlmanacOmegaDot_constraint_1, + &ASN_PER_MEMB_KEP_ALMANAC_OMEGA_DOT_CONSTR_4, 0, "kepAlmanacOmegaDot"}, {ATF_NOFLAGS, 0, offsetof(struct Almanac_KeplerianSet, kepSVHealth), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_kepSVHealth_constraint_1, - &ASN_PER_MEMB_KEP_SV_HEALTH_CONSTR_5, 0, "kepSVHealth"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_kepSVHealth_constraint_1, + &ASN_PER_MEMB_KEP_SV_HEALTH_CONSTR_5, 0, "kepSVHealth"}, {ATF_NOFLAGS, 0, - offsetof(struct Almanac_KeplerianSet, kepAlmanacAPowerHalf), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_kepAlmanacAPowerHalf_constraint_1, - &ASN_PER_MEMB_KEP_ALMANAC_A_POWER_HALF_CONSTR_6, 0, - "kepAlmanacAPowerHalf"}, + offsetof(struct Almanac_KeplerianSet, kepAlmanacAPowerHalf), + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_kepAlmanacAPowerHalf_constraint_1, + &ASN_PER_MEMB_KEP_ALMANAC_A_POWER_HALF_CONSTR_6, 0, + "kepAlmanacAPowerHalf"}, {ATF_NOFLAGS, 0, offsetof(struct Almanac_KeplerianSet, kepAlmanacOmega0), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_kepAlmanacOmega0_constraint_1, - &ASN_PER_MEMB_KEP_ALMANAC_OMEGA0_CONSTR_7, 0, "kepAlmanacOmega0"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_kepAlmanacOmega0_constraint_1, + &ASN_PER_MEMB_KEP_ALMANAC_OMEGA0_CONSTR_7, 0, "kepAlmanacOmega0"}, {ATF_NOFLAGS, 0, offsetof(struct Almanac_KeplerianSet, kepAlmanacW), - (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_kepAlmanacW_constraint_1, - &ASN_PER_MEMB_KEP_ALMANAC_W_CONSTR_8, 0, "kepAlmanacW"}, + (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_kepAlmanacW_constraint_1, + &ASN_PER_MEMB_KEP_ALMANAC_W_CONSTR_8, 0, "kepAlmanacW"}, {ATF_NOFLAGS, 0, offsetof(struct Almanac_KeplerianSet, kepAlmanacM0), - (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_kepAlmanacM0_constraint_1, - &ASN_PER_MEMB_KEP_ALMANAC_M0_CONSTR_9, 0, "kepAlmanacM0"}, + (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_kepAlmanacM0_constraint_1, + &ASN_PER_MEMB_KEP_ALMANAC_M0_CONSTR_9, 0, "kepAlmanacM0"}, {ATF_NOFLAGS, 0, offsetof(struct Almanac_KeplerianSet, kepAlmanacAF0), - (ASN_TAG_CLASS_CONTEXT | (8 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_kepAlmanacAF0_constraint_1, - &ASN_PER_MEMB_KEP_ALMANAC_A_F0_CONSTR_10, 0, "kepAlmanacAF0"}, + (ASN_TAG_CLASS_CONTEXT | (8 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_kepAlmanacAF0_constraint_1, + &ASN_PER_MEMB_KEP_ALMANAC_A_F0_CONSTR_10, 0, "kepAlmanacAF0"}, {ATF_NOFLAGS, 0, offsetof(struct Almanac_KeplerianSet, kepAlmanacAF1), - (ASN_TAG_CLASS_CONTEXT | (9 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_kepAlmanacAF1_constraint_1, - &ASN_PER_MEMB_KEP_ALMANAC_A_F1_CONSTR_11, 0, "kepAlmanacAF1"}, + (ASN_TAG_CLASS_CONTEXT | (9 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_kepAlmanacAF1_constraint_1, + &ASN_PER_MEMB_KEP_ALMANAC_A_F1_CONSTR_11, 0, "kepAlmanacAF1"}, }; static ber_tlv_tag_t asn_DEF_Almanac_KeplerianSet_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_Almanac_KeplerianSet_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* kepAlmanacE at 1368 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0}, /* kepAlmanacDeltaI at 1369 */ + 0}, /* kepAlmanacDeltaI at 1369 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, - 0}, /* kepAlmanacOmegaDot at 1370 */ + 0}, /* kepAlmanacOmegaDot at 1370 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, 0}, /* kepSVHealth at 1371 */ {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, - 0}, /* kepAlmanacAPowerHalf at 1372 */ + 0}, /* kepAlmanacAPowerHalf at 1372 */ {(ASN_TAG_CLASS_CONTEXT | (5 << 2)), 5, 0, - 0}, /* kepAlmanacOmega0 at 1373 */ + 0}, /* kepAlmanacOmega0 at 1373 */ {(ASN_TAG_CLASS_CONTEXT | (6 << 2)), 6, 0, 0}, /* kepAlmanacW at 1374 */ {(ASN_TAG_CLASS_CONTEXT | (7 << 2)), 7, 0, 0}, /* kepAlmanacM0 at 1375 */ {(ASN_TAG_CLASS_CONTEXT | (8 << 2)), 8, 0, 0}, /* kepAlmanacAF0 at 1376 */ @@ -442,7 +442,7 @@ asn_TYPE_descriptor_t asn_DEF_Almanac_KeplerianSet = { asn_DEF_Almanac_KeplerianSet_tags_1, /* Same as above */ sizeof(asn_DEF_Almanac_KeplerianSet_tags_1) / sizeof(asn_DEF_Almanac_KeplerianSet_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_Almanac_KeplerianSet_1, 10, /* Elements count */ &asn_SPC_Almanac_KeplerianSet_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/Almanac.c b/src/core/libs/supl/asn-rrlp/Almanac.c index 5ae28396a..99b5c1b69 100644 --- a/src/core/libs/supl/asn-rrlp/Almanac.c +++ b/src/core/libs/supl/asn-rrlp/Almanac.c @@ -7,16 +7,16 @@ #include "Almanac.h" static int memb_alamanacWNa_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,7 +30,7 @@ static int memb_alamanacWNa_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -43,15 +43,15 @@ static asn_per_constraints_t ASN_PER_MEMB_ALAMANAC_W_NA_CONSTR_2 = { }; static asn_TYPE_member_t asn_MBR_Almanac_1[] = { {ATF_NOFLAGS, 0, offsetof(struct Almanac, alamanacWNa), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_alamanacWNa_constraint_1, - &ASN_PER_MEMB_ALAMANAC_W_NA_CONSTR_2, 0, "alamanacWNa"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_alamanacWNa_constraint_1, + &ASN_PER_MEMB_ALAMANAC_W_NA_CONSTR_2, 0, "alamanacWNa"}, {ATF_NOFLAGS, 0, offsetof(struct Almanac, almanacList), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfAlmanacElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "almanacList"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfAlmanacElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "almanacList"}, }; static ber_tlv_tag_t asn_DEF_Almanac_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -85,9 +85,9 @@ asn_TYPE_descriptor_t asn_DEF_Almanac = { 0, /* Use generic outmost tag fetcher */ asn_DEF_Almanac_tags_1, sizeof(asn_DEF_Almanac_tags_1) / sizeof(asn_DEF_Almanac_tags_1[0]), /* 1 */ - asn_DEF_Almanac_tags_1, /* Same as above */ + asn_DEF_Almanac_tags_1, /* Same as above */ sizeof(asn_DEF_Almanac_tags_1) / sizeof(asn_DEF_Almanac_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_Almanac_1, 2, /* Elements count */ &asn_SPC_Almanac_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/Almanac.h b/src/core/libs/supl/asn-rrlp/Almanac.h index 44c4e7dce..c4cab5edc 100644 --- a/src/core/libs/supl/asn-rrlp/Almanac.h +++ b/src/core/libs/supl/asn-rrlp/Almanac.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include #include "SeqOfAlmanacElement.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/AlmanacElement.c b/src/core/libs/supl/asn-rrlp/AlmanacElement.c index 1991b1337..12d4d67b5 100644 --- a/src/core/libs/supl/asn-rrlp/AlmanacElement.c +++ b/src/core/libs/supl/asn-rrlp/AlmanacElement.c @@ -7,16 +7,16 @@ #include "AlmanacElement.h" static int memb_almanacE_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,22 +30,22 @@ static int memb_almanacE_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_alamanacToa_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -59,22 +59,22 @@ static int memb_alamanacToa_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_almanacKsii_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -88,7 +88,7 @@ static int memb_almanacKsii_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -102,7 +102,7 @@ static int memb_almanacOmegaDot_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -116,7 +116,7 @@ static int memb_almanacOmegaDot_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -130,7 +130,7 @@ static int memb_almanacSVhealth_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -144,7 +144,7 @@ static int memb_almanacSVhealth_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -158,7 +158,7 @@ static int memb_almanacAPowerHalf_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -172,7 +172,7 @@ static int memb_almanacAPowerHalf_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -186,7 +186,7 @@ static int memb_almanacOmega0_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -200,22 +200,22 @@ static int memb_almanacOmega0_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_almanacW_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -229,22 +229,22 @@ static int memb_almanacW_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_almanacM0_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -258,22 +258,22 @@ static int memb_almanacM0_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_almanacAF0_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -287,22 +287,22 @@ static int memb_almanacAF0_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_almanacAF1_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -316,7 +316,7 @@ static int memb_almanacAF1_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -389,57 +389,57 @@ static asn_per_constraints_t ASN_PER_MEMB_ALMANAC_A_F1_CONSTR_13 = { }; static asn_TYPE_member_t asn_MBR_AlmanacElement_1[] = { {ATF_NOFLAGS, 0, offsetof(struct AlmanacElement, satelliteID), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SatelliteID, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "satelliteID"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SatelliteID, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "satelliteID"}, {ATF_NOFLAGS, 0, offsetof(struct AlmanacElement, almanacE), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_almanacE_constraint_1, - &ASN_PER_MEMB_ALMANAC_E_CONSTR_3, 0, "almanacE"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_almanacE_constraint_1, + &ASN_PER_MEMB_ALMANAC_E_CONSTR_3, 0, "almanacE"}, {ATF_NOFLAGS, 0, offsetof(struct AlmanacElement, alamanacToa), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_alamanacToa_constraint_1, - &ASN_PER_MEMB_ALAMANAC_TOA_CONSTR_4, 0, "alamanacToa"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_alamanacToa_constraint_1, + &ASN_PER_MEMB_ALAMANAC_TOA_CONSTR_4, 0, "alamanacToa"}, {ATF_NOFLAGS, 0, offsetof(struct AlmanacElement, almanacKsii), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_almanacKsii_constraint_1, - &ASN_PER_MEMB_ALMANAC_KSII_CONSTR_5, 0, "almanacKsii"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_almanacKsii_constraint_1, + &ASN_PER_MEMB_ALMANAC_KSII_CONSTR_5, 0, "almanacKsii"}, {ATF_NOFLAGS, 0, offsetof(struct AlmanacElement, almanacOmegaDot), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_almanacOmegaDot_constraint_1, - &ASN_PER_MEMB_ALMANAC_OMEGA_DOT_CONSTR_6, 0, "almanacOmegaDot"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_almanacOmegaDot_constraint_1, + &ASN_PER_MEMB_ALMANAC_OMEGA_DOT_CONSTR_6, 0, "almanacOmegaDot"}, {ATF_NOFLAGS, 0, offsetof(struct AlmanacElement, almanacSVhealth), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_almanacSVhealth_constraint_1, - &ASN_PER_MEMB_ALMANAC_S_VHEALTH_CONSTR_7, 0, "almanacSVhealth"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_almanacSVhealth_constraint_1, + &ASN_PER_MEMB_ALMANAC_S_VHEALTH_CONSTR_7, 0, "almanacSVhealth"}, {ATF_NOFLAGS, 0, offsetof(struct AlmanacElement, almanacAPowerHalf), - (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_almanacAPowerHalf_constraint_1, - &ASN_PER_MEMB_ALMANAC_A_POWER_HALF_CONSTR_8, 0, "almanacAPowerHalf"}, + (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_almanacAPowerHalf_constraint_1, + &ASN_PER_MEMB_ALMANAC_A_POWER_HALF_CONSTR_8, 0, "almanacAPowerHalf"}, {ATF_NOFLAGS, 0, offsetof(struct AlmanacElement, almanacOmega0), - (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_almanacOmega0_constraint_1, - &ASN_PER_MEMB_ALMANAC_OMEGA0_CONSTR_9, 0, "almanacOmega0"}, + (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_almanacOmega0_constraint_1, + &ASN_PER_MEMB_ALMANAC_OMEGA0_CONSTR_9, 0, "almanacOmega0"}, {ATF_NOFLAGS, 0, offsetof(struct AlmanacElement, almanacW), - (ASN_TAG_CLASS_CONTEXT | (8 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_almanacW_constraint_1, - &ASN_PER_MEMB_ALMANAC_W_CONSTR_10, 0, "almanacW"}, + (ASN_TAG_CLASS_CONTEXT | (8 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_almanacW_constraint_1, + &ASN_PER_MEMB_ALMANAC_W_CONSTR_10, 0, "almanacW"}, {ATF_NOFLAGS, 0, offsetof(struct AlmanacElement, almanacM0), - (ASN_TAG_CLASS_CONTEXT | (9 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_almanacM0_constraint_1, - &ASN_PER_MEMB_ALMANAC_M0_CONSTR_11, 0, "almanacM0"}, + (ASN_TAG_CLASS_CONTEXT | (9 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_almanacM0_constraint_1, + &ASN_PER_MEMB_ALMANAC_M0_CONSTR_11, 0, "almanacM0"}, {ATF_NOFLAGS, 0, offsetof(struct AlmanacElement, almanacAF0), - (ASN_TAG_CLASS_CONTEXT | (10 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_almanacAF0_constraint_1, - &ASN_PER_MEMB_ALMANAC_A_F0_CONSTR_12, 0, "almanacAF0"}, + (ASN_TAG_CLASS_CONTEXT | (10 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_almanacAF0_constraint_1, + &ASN_PER_MEMB_ALMANAC_A_F0_CONSTR_12, 0, "almanacAF0"}, {ATF_NOFLAGS, 0, offsetof(struct AlmanacElement, almanacAF1), - (ASN_TAG_CLASS_CONTEXT | (11 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_almanacAF1_constraint_1, - &ASN_PER_MEMB_ALMANAC_A_F1_CONSTR_13, 0, "almanacAF1"}, + (ASN_TAG_CLASS_CONTEXT | (11 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_almanacAF1_constraint_1, + &ASN_PER_MEMB_ALMANAC_A_F1_CONSTR_13, 0, "almanacAF1"}, }; static ber_tlv_tag_t asn_DEF_AlmanacElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -451,7 +451,7 @@ static asn_TYPE_tag2member_t asn_MAP_AlmanacElement_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, 0}, /* almanacOmegaDot at 803 */ {(ASN_TAG_CLASS_CONTEXT | (5 << 2)), 5, 0, 0}, /* almanacSVhealth at 804 */ {(ASN_TAG_CLASS_CONTEXT | (6 << 2)), 6, 0, - 0}, /* almanacAPowerHalf at 805 */ + 0}, /* almanacAPowerHalf at 805 */ {(ASN_TAG_CLASS_CONTEXT | (7 << 2)), 7, 0, 0}, /* almanacOmega0 at 806 */ {(ASN_TAG_CLASS_CONTEXT | (8 << 2)), 8, 0, 0}, /* almanacW at 807 */ {(ASN_TAG_CLASS_CONTEXT | (9 << 2)), 9, 0, 0}, /* almanacM0 at 808 */ @@ -488,7 +488,7 @@ asn_TYPE_descriptor_t asn_DEF_AlmanacElement = { asn_DEF_AlmanacElement_tags_1, /* Same as above */ sizeof(asn_DEF_AlmanacElement_tags_1) / sizeof(asn_DEF_AlmanacElement_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_AlmanacElement_1, 12, /* Elements count */ &asn_SPC_AlmanacElement_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/AntiSpoofFlag.c b/src/core/libs/supl/asn-rrlp/AntiSpoofFlag.c index 84628ced9..13f6474ed 100644 --- a/src/core/libs/supl/asn-rrlp/AntiSpoofFlag.c +++ b/src/core/libs/supl/asn-rrlp/AntiSpoofFlag.c @@ -7,15 +7,15 @@ #include "AntiSpoofFlag.h" int AntiSpoofFlag_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ int AntiSpoofFlag_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -56,74 +56,74 @@ static void AntiSpoofFlag_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void AntiSpoofFlag_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { AntiSpoofFlag_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int AntiSpoofFlag_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { AntiSpoofFlag_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t AntiSpoofFlag_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { AntiSpoofFlag_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t AntiSpoofFlag_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { AntiSpoofFlag_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t AntiSpoofFlag_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, const char *opt_mname, + const void *bufptr, size_t size) { AntiSpoofFlag_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t AntiSpoofFlag_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { AntiSpoofFlag_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t AntiSpoofFlag_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { AntiSpoofFlag_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t AntiSpoofFlag_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { AntiSpoofFlag_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/AssistBTSData-R98-ExpOTD.c b/src/core/libs/supl/asn-rrlp/AssistBTSData-R98-ExpOTD.c index 496935420..9a7e1842d 100644 --- a/src/core/libs/supl/asn-rrlp/AssistBTSData-R98-ExpOTD.c +++ b/src/core/libs/supl/asn-rrlp/AssistBTSData-R98-ExpOTD.c @@ -8,24 +8,24 @@ static asn_TYPE_member_t asn_MBR_AssistBTSData_R98_ExpOTD_1[] = { {ATF_NOFLAGS, 0, offsetof(struct AssistBTSData_R98_ExpOTD, expectedOTD), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_ExpectedOTD, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "expectedOTD"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_ExpectedOTD, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "expectedOTD"}, {ATF_NOFLAGS, 0, - offsetof(struct AssistBTSData_R98_ExpOTD, expOTDuncertainty), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_ExpOTDUncertainty, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "expOTDuncertainty"}, + offsetof(struct AssistBTSData_R98_ExpOTD, expOTDuncertainty), + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_ExpOTDUncertainty, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "expOTDuncertainty"}, }; static ber_tlv_tag_t asn_DEF_AssistBTSData_R98_ExpOTD_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_AssistBTSData_R98_ExpOTD_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* expectedOTD at 933 */ - {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0} /* expOTDuncertainty at 935 */ + {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0} /* expOTDuncertainty at 935 */ }; static asn_SEQUENCE_specifics_t asn_SPC_AssistBTSData_R98_ExpOTD_specs_1 = { sizeof(struct AssistBTSData_R98_ExpOTD), @@ -57,7 +57,7 @@ asn_TYPE_descriptor_t asn_DEF_AssistBTSData_R98_ExpOTD = { asn_DEF_AssistBTSData_R98_ExpOTD_tags_1, /* Same as above */ sizeof(asn_DEF_AssistBTSData_R98_ExpOTD_tags_1) / sizeof(asn_DEF_AssistBTSData_R98_ExpOTD_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_AssistBTSData_R98_ExpOTD_1, 2, /* Elements count */ &asn_SPC_AssistBTSData_R98_ExpOTD_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/AssistBTSData-R98-ExpOTD.h b/src/core/libs/supl/asn-rrlp/AssistBTSData-R98-ExpOTD.h index f661bf8c9..08a05e194 100644 --- a/src/core/libs/supl/asn-rrlp/AssistBTSData-R98-ExpOTD.h +++ b/src/core/libs/supl/asn-rrlp/AssistBTSData-R98-ExpOTD.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include "ExpectedOTD.h" #include "ExpOTDUncertainty.h" +#include "ExpectedOTD.h" #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/AssistBTSData.c b/src/core/libs/supl/asn-rrlp/AssistBTSData.c index d95713fc5..cfca643d7 100644 --- a/src/core/libs/supl/asn-rrlp/AssistBTSData.c +++ b/src/core/libs/supl/asn-rrlp/AssistBTSData.c @@ -8,33 +8,33 @@ static asn_TYPE_member_t asn_MBR_AssistBTSData_1[] = { {ATF_NOFLAGS, 0, offsetof(struct AssistBTSData, bsic), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BSIC, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "bsic"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BSIC, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "bsic"}, {ATF_NOFLAGS, 0, offsetof(struct AssistBTSData, multiFrameOffset), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_MultiFrameOffset, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "multiFrameOffset"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_MultiFrameOffset, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "multiFrameOffset"}, {ATF_NOFLAGS, 0, offsetof(struct AssistBTSData, timeSlotScheme), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_TimeSlotScheme, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "timeSlotScheme"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_TimeSlotScheme, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "timeSlotScheme"}, {ATF_NOFLAGS, 0, offsetof(struct AssistBTSData, roughRTD), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_RoughRTD, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "roughRTD"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_RoughRTD, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "roughRTD"}, {ATF_POINTER, 1, offsetof(struct AssistBTSData, calcAssistanceBTS), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_CalcAssistanceBTS, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "calcAssistanceBTS"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_CalcAssistanceBTS, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "calcAssistanceBTS"}, }; static int asn_MAP_AssistBTSData_oms_1[] = {4}; static ber_tlv_tag_t asn_DEF_AssistBTSData_tags_1[] = { @@ -44,7 +44,7 @@ static asn_TYPE_tag2member_t asn_MAP_AssistBTSData_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0}, /* multiFrameOffset at 230 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0}, /* timeSlotScheme at 231 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, 0}, /* roughRTD at 232 */ - {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, 0} /* calcAssistanceBTS at 235 */ + {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, 0} /* calcAssistanceBTS at 235 */ }; static asn_SEQUENCE_specifics_t asn_SPC_AssistBTSData_specs_1 = { sizeof(struct AssistBTSData), @@ -76,7 +76,7 @@ asn_TYPE_descriptor_t asn_DEF_AssistBTSData = { asn_DEF_AssistBTSData_tags_1, /* Same as above */ sizeof(asn_DEF_AssistBTSData_tags_1) / sizeof(asn_DEF_AssistBTSData_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_AssistBTSData_1, 5, /* Elements count */ &asn_SPC_AssistBTSData_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/AssistBTSData.h b/src/core/libs/supl/asn-rrlp/AssistBTSData.h index 31ca04098..e0032073e 100644 --- a/src/core/libs/supl/asn-rrlp/AssistBTSData.h +++ b/src/core/libs/supl/asn-rrlp/AssistBTSData.h @@ -12,8 +12,8 @@ /* Including external dependencies */ #include "BSIC.h" #include "MultiFrameOffset.h" -#include "TimeSlotScheme.h" #include "RoughRTD.h" +#include "TimeSlotScheme.h" #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/AssistanceData.c b/src/core/libs/supl/asn-rrlp/AssistanceData.c index d07a671c6..6e1aa5c0f 100644 --- a/src/core/libs/supl/asn-rrlp/AssistanceData.c +++ b/src/core/libs/supl/asn-rrlp/AssistanceData.c @@ -8,74 +8,74 @@ static asn_TYPE_member_t asn_MBR_AssistanceData_1[] = { {ATF_POINTER, 8, offsetof(struct AssistanceData, referenceAssistData), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_ReferenceAssistData, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "referenceAssistData"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_ReferenceAssistData, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "referenceAssistData"}, {ATF_POINTER, 7, offsetof(struct AssistanceData, msrAssistData), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_MsrAssistData, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "msrAssistData"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_MsrAssistData, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "msrAssistData"}, {ATF_POINTER, 6, offsetof(struct AssistanceData, systemInfoAssistData), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SystemInfoAssistData, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "systemInfoAssistData"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SystemInfoAssistData, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "systemInfoAssistData"}, {ATF_POINTER, 5, offsetof(struct AssistanceData, gps_AssistData), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GPS_AssistData, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "gps-AssistData"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GPS_AssistData, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "gps-AssistData"}, {ATF_POINTER, 4, offsetof(struct AssistanceData, moreAssDataToBeSent), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_MoreAssDataToBeSent, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "moreAssDataToBeSent"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_MoreAssDataToBeSent, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "moreAssDataToBeSent"}, {ATF_POINTER, 3, offsetof(struct AssistanceData, extensionContainer), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_ExtensionContainer, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "extensionContainer"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_ExtensionContainer, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "extensionContainer"}, {ATF_POINTER, 2, - offsetof(struct AssistanceData, rel98_AssistanceData_Extension), - (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Rel98_AssistanceData_Extension, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "rel98-AssistanceData-Extension"}, + offsetof(struct AssistanceData, rel98_AssistanceData_Extension), + (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Rel98_AssistanceData_Extension, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "rel98-AssistanceData-Extension"}, {ATF_POINTER, 1, - offsetof(struct AssistanceData, rel5_AssistanceData_Extension), - (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Rel5_AssistanceData_Extension, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "rel5-AssistanceData-Extension"}, + offsetof(struct AssistanceData, rel5_AssistanceData_Extension), + (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Rel5_AssistanceData_Extension, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "rel5-AssistanceData-Extension"}, }; static int asn_MAP_AssistanceData_oms_1[] = {0, 1, 2, 3, 4, 5, 6, 7}; static ber_tlv_tag_t asn_DEF_AssistanceData_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_AssistanceData_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0}, /* referenceAssistData at 75 */ + 0}, /* referenceAssistData at 75 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0}, /* msrAssistData at 76 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, - 0}, /* systemInfoAssistData at 77 */ + 0}, /* systemInfoAssistData at 77 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, 0}, /* gps-AssistData at 78 */ {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, - 0}, /* moreAssDataToBeSent at 79 */ + 0}, /* moreAssDataToBeSent at 79 */ {(ASN_TAG_CLASS_CONTEXT | (5 << 2)), 5, 0, - 0}, /* extensionContainer at 83 */ + 0}, /* extensionContainer at 83 */ {(ASN_TAG_CLASS_CONTEXT | (6 << 2)), 6, 0, - 0}, /* rel98-AssistanceData-Extension at 86 */ + 0}, /* rel98-AssistanceData-Extension at 86 */ {(ASN_TAG_CLASS_CONTEXT | (7 << 2)), 7, 0, - 0} /* rel5-AssistanceData-Extension at 87 */ + 0} /* rel5-AssistanceData-Extension at 87 */ }; static asn_SEQUENCE_specifics_t asn_SPC_AssistanceData_specs_1 = { sizeof(struct AssistanceData), @@ -107,7 +107,7 @@ asn_TYPE_descriptor_t asn_DEF_AssistanceData = { asn_DEF_AssistanceData_tags_1, /* Same as above */ sizeof(asn_DEF_AssistanceData_tags_1) / sizeof(asn_DEF_AssistanceData_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_AssistanceData_1, 8, /* Elements count */ &asn_SPC_AssistanceData_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/AssistanceData.h b/src/core/libs/supl/asn-rrlp/AssistanceData.h index 25b9da129..6eb0cf56f 100644 --- a/src/core/libs/supl/asn-rrlp/AssistanceData.h +++ b/src/core/libs/supl/asn-rrlp/AssistanceData.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include "MoreAssDataToBeSent.h" #include "ExtensionContainer.h" +#include "MoreAssDataToBeSent.h" #include #ifdef __cplusplus @@ -57,12 +57,12 @@ extern "C" #endif /* Referred external types */ -#include "ReferenceAssistData.h" -#include "MsrAssistData.h" -#include "SystemInfoAssistData.h" #include "GPS-AssistData.h" -#include "Rel98-AssistanceData-Extension.h" +#include "MsrAssistData.h" +#include "ReferenceAssistData.h" #include "Rel5-AssistanceData-Extension.h" +#include "Rel98-AssistanceData-Extension.h" +#include "SystemInfoAssistData.h" #endif /* _AssistanceData_H_ */ #include diff --git a/src/core/libs/supl/asn-rrlp/BCCHCarrier.c b/src/core/libs/supl/asn-rrlp/BCCHCarrier.c index 861086e4e..f88d17619 100644 --- a/src/core/libs/supl/asn-rrlp/BCCHCarrier.c +++ b/src/core/libs/supl/asn-rrlp/BCCHCarrier.c @@ -7,14 +7,14 @@ #include "BCCHCarrier.h" int BCCHCarrier_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int BCCHCarrier_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -55,73 +55,73 @@ static void BCCHCarrier_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void BCCHCarrier_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { BCCHCarrier_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int BCCHCarrier_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { BCCHCarrier_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t BCCHCarrier_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { BCCHCarrier_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t BCCHCarrier_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { BCCHCarrier_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t BCCHCarrier_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, const char *opt_mname, + const void *bufptr, size_t size) { BCCHCarrier_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t BCCHCarrier_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { BCCHCarrier_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t BCCHCarrier_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { BCCHCarrier_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t BCCHCarrier_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { BCCHCarrier_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/BIT_STRING.c b/src/core/libs/supl/asn-rrlp/BIT_STRING.c index 8439afc33..6e958c1bf 100644 --- a/src/core/libs/supl/asn-rrlp/BIT_STRING.c +++ b/src/core/libs/supl/asn-rrlp/BIT_STRING.c @@ -2,7 +2,6 @@ * Copyright (c) 2003, 2004 Lev Walkin . All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ -#include #include #include @@ -39,7 +38,7 @@ asn_TYPE_descriptor_t asn_DEF_BIT_STRING = { * BIT STRING generic constraint. */ int BIT_STRING_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { const BIT_STRING_t *st = (const BIT_STRING_t *)sptr; @@ -49,15 +48,15 @@ int BIT_STRING_constraint(asn_TYPE_descriptor_t *td, const void *sptr, st->bits_unused > 7) { _ASN_CTFAIL(app_key, td, sptr, - "%s: invalid padding byte (%s:%d)", td->name, - __FILE__, __LINE__); + "%s: invalid padding byte (%s:%d)", td->name, + __FILE__, __LINE__); return -1; } } else { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -65,12 +64,12 @@ int BIT_STRING_constraint(asn_TYPE_descriptor_t *td, const void *sptr, } static char *_bit_pattern[16] = {"0000", "0001", "0010", "0011", "0100", "0101", - "0110", "0111", "1000", "1001", "1010", "1011", - "1100", "1101", "1110", "1111"}; + "0110", "0111", "1000", "1001", "1010", "1011", + "1100", "1101", "1110", "1111"}; asn_enc_rval_t BIT_STRING_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { asn_enc_rval_t er; char scratch[128]; @@ -133,7 +132,7 @@ cb_failed: * BIT STRING specific contents printer. */ int BIT_STRING_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { static const char *h2c = "0123456789ABCDEF"; char scratch[64]; diff --git a/src/core/libs/supl/asn-rrlp/BOOLEAN.c b/src/core/libs/supl/asn-rrlp/BOOLEAN.c index 985f2638e..57ae3ac29 100644 --- a/src/core/libs/supl/asn-rrlp/BOOLEAN.c +++ b/src/core/libs/supl/asn-rrlp/BOOLEAN.c @@ -2,9 +2,9 @@ * Copyright (c) 2003, 2005 Lev Walkin . All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ -#include -#include #include +#include +#include /* * BOOLEAN basic type description. @@ -38,9 +38,9 @@ asn_TYPE_descriptor_t asn_DEF_BOOLEAN = { * Decode BOOLEAN type. */ asn_dec_rval_t BOOLEAN_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **bool_value, - const void *buf_ptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, void **bool_value, + const void *buf_ptr, size_t size, + int tag_mode) { BOOLEAN_t *st = (BOOLEAN_t *)*bool_value; asn_dec_rval_t rval; @@ -64,7 +64,7 @@ asn_dec_rval_t BOOLEAN_decode_ber(asn_codec_ctx_t *opt_codec_ctx, * Check tags. */ rval = ber_check_tags(opt_codec_ctx, td, 0, buf_ptr, size, tag_mode, 0, - &length, 0); + &length, 0); if (rval.code != RC_OK) return rval; ASN_DEBUG("Boolean length is %d bytes", (int)length); @@ -95,14 +95,14 @@ asn_dec_rval_t BOOLEAN_decode_ber(asn_codec_ctx_t *opt_codec_ctx, rval.consumed += length; ASN_DEBUG("Took %ld/%ld bytes to encode %s, value=%d", (long)rval.consumed, - (long)length, td->name, *st); + (long)length, td->name, *st); return rval; } asn_enc_rval_t BOOLEAN_encode_der(asn_TYPE_descriptor_t *td, void *sptr, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { asn_enc_rval_t erval; BOOLEAN_t *st = (BOOLEAN_t *)sptr; @@ -139,9 +139,9 @@ asn_enc_rval_t BOOLEAN_encode_der(asn_TYPE_descriptor_t *td, void *sptr, * Decode the chunk of XML text encoding INTEGER. */ static enum xer_pbd_rval BOOLEAN__xer_body_decode(asn_TYPE_descriptor_t *td, - void *sptr, - const void *chunk_buf, - size_t chunk_size) + void *sptr, + const void *chunk_buf, + size_t chunk_size) { BOOLEAN_t *st = (BOOLEAN_t *)sptr; const char *p = (const char *)chunk_buf; @@ -152,19 +152,19 @@ static enum xer_pbd_rval BOOLEAN__xer_body_decode(asn_TYPE_descriptor_t *td, { switch (xer_check_tag(chunk_buf, chunk_size, "false")) { - case XCT_BOTH: - /* "" */ - *st = 0; - break; - case XCT_UNKNOWN_BO: - if (xer_check_tag(chunk_buf, chunk_size, "true") != - XCT_BOTH) - return XPBD_BROKEN_ENCODING; - /* "" */ - *st = 1; /* Or 0xff as in DER?.. */ - break; - default: + case XCT_BOTH: + /* "" */ + *st = 0; + break; + case XCT_UNKNOWN_BO: + if (xer_check_tag(chunk_buf, chunk_size, "true") != + XCT_BOTH) return XPBD_BROKEN_ENCODING; + /* "" */ + *st = 1; /* Or 0xff as in DER?.. */ + break; + default: + return XPBD_BROKEN_ENCODING; } return XPBD_BODY_CONSUMED; } @@ -178,18 +178,18 @@ static enum xer_pbd_rval BOOLEAN__xer_body_decode(asn_TYPE_descriptor_t *td, } asn_dec_rval_t BOOLEAN_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **sptr, - const char *opt_mname, const void *buf_ptr, - size_t size) + asn_TYPE_descriptor_t *td, void **sptr, + const char *opt_mname, const void *buf_ptr, + size_t size) { return xer_decode_primitive(opt_codec_ctx, td, sptr, sizeof(BOOLEAN_t), - opt_mname, buf_ptr, size, - BOOLEAN__xer_body_decode); + opt_mname, buf_ptr, size, + BOOLEAN__xer_body_decode); } asn_enc_rval_t BOOLEAN_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { const BOOLEAN_t *st = (const BOOLEAN_t *)sptr; asn_enc_rval_t er; @@ -216,7 +216,7 @@ cb_failed: } int BOOLEAN_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { const BOOLEAN_t *st = (const BOOLEAN_t *)sptr; const char *buf; @@ -256,9 +256,9 @@ void BOOLEAN_free(asn_TYPE_descriptor_t *td, void *ptr, int contents_only) } asn_dec_rval_t BOOLEAN_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd) { asn_dec_rval_t rv; BOOLEAN_t *st = (BOOLEAN_t *)*sptr; @@ -277,15 +277,15 @@ asn_dec_rval_t BOOLEAN_decode_uper(asn_codec_ctx_t *opt_codec_ctx, */ switch (per_get_few_bits(pd, 1)) { - case 1: - *st = 1; - break; - case 0: - *st = 0; - break; - case -1: - default: - _ASN_DECODE_STARVED; + case 1: + *st = 1; + break; + case 0: + *st = 0; + break; + case -1: + default: + _ASN_DECODE_STARVED; } ASN_DEBUG("%s decoded as %s", td->name, *st ? "TRUE" : "FALSE"); @@ -296,8 +296,8 @@ asn_dec_rval_t BOOLEAN_decode_uper(asn_codec_ctx_t *opt_codec_ctx, } asn_enc_rval_t BOOLEAN_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *sptr, asn_per_outp_t *po) + asn_per_constraints_t *constraints, + void *sptr, asn_per_outp_t *po) { const BOOLEAN_t *st = (const BOOLEAN_t *)sptr; asn_enc_rval_t er; diff --git a/src/core/libs/supl/asn-rrlp/BSIC.c b/src/core/libs/supl/asn-rrlp/BSIC.c index ce7b30ad0..6d84f0c3f 100644 --- a/src/core/libs/supl/asn-rrlp/BSIC.c +++ b/src/core/libs/supl/asn-rrlp/BSIC.c @@ -7,14 +7,14 @@ #include "BSIC.h" int BSIC_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int BSIC_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -61,60 +61,60 @@ void BSIC_free(asn_TYPE_descriptor_t *td, void *struct_ptr, int contents_only) } int BSIC_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { BSIC_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t BSIC_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, int tag_mode) { BSIC_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t BSIC_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { BSIC_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t BSIC_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { BSIC_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t BSIC_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { BSIC_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t BSIC_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { BSIC_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t BSIC_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { BSIC_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); @@ -143,7 +143,7 @@ asn_TYPE_descriptor_t asn_DEF_BSIC = { 0, /* Use generic outmost tag fetcher */ asn_DEF_BSIC_tags_1, sizeof(asn_DEF_BSIC_tags_1) / sizeof(asn_DEF_BSIC_tags_1[0]), /* 1 */ - asn_DEF_BSIC_tags_1, /* Same as above */ + asn_DEF_BSIC_tags_1, /* Same as above */ sizeof(asn_DEF_BSIC_tags_1) / sizeof(asn_DEF_BSIC_tags_1[0]), /* 1 */ &ASN_PER_TYPE_BSIC_CONSTR_1, 0, diff --git a/src/core/libs/supl/asn-rrlp/BSICAndCarrier.c b/src/core/libs/supl/asn-rrlp/BSICAndCarrier.c index 7ec6c745f..b7fd94da1 100644 --- a/src/core/libs/supl/asn-rrlp/BSICAndCarrier.c +++ b/src/core/libs/supl/asn-rrlp/BSICAndCarrier.c @@ -8,16 +8,16 @@ static asn_TYPE_member_t asn_MBR_BSICAndCarrier_1[] = { {ATF_NOFLAGS, 0, offsetof(struct BSICAndCarrier, carrier), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BCCHCarrier, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "carrier"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BCCHCarrier, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "carrier"}, {ATF_NOFLAGS, 0, offsetof(struct BSICAndCarrier, bsic), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BSIC, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "bsic"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BSIC, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "bsic"}, }; static ber_tlv_tag_t asn_DEF_BSICAndCarrier_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -55,7 +55,7 @@ asn_TYPE_descriptor_t asn_DEF_BSICAndCarrier = { asn_DEF_BSICAndCarrier_tags_1, /* Same as above */ sizeof(asn_DEF_BSICAndCarrier_tags_1) / sizeof(asn_DEF_BSICAndCarrier_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_BSICAndCarrier_1, 2, /* Elements count */ &asn_SPC_BSICAndCarrier_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/BTSPosition.c b/src/core/libs/supl/asn-rrlp/BTSPosition.c index a66dee5ba..f7369ecde 100644 --- a/src/core/libs/supl/asn-rrlp/BTSPosition.c +++ b/src/core/libs/supl/asn-rrlp/BTSPosition.c @@ -7,7 +7,7 @@ #include "BTSPosition.h" int BTSPosition_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { const Ext_GeographicalInformation_t *st = (const Ext_GeographicalInformation_t *)sptr; @@ -16,7 +16,7 @@ int BTSPosition_constraint(asn_TYPE_descriptor_t *td, const void *sptr, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,7 +30,7 @@ int BTSPosition_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -58,73 +58,73 @@ static void BTSPosition_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void BTSPosition_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { BTSPosition_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int BTSPosition_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { BTSPosition_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t BTSPosition_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { BTSPosition_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t BTSPosition_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { BTSPosition_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t BTSPosition_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, const char *opt_mname, + const void *bufptr, size_t size) { BTSPosition_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t BTSPosition_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { BTSPosition_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t BTSPosition_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { BTSPosition_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t BTSPosition_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { BTSPosition_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/BadSignalElement.c b/src/core/libs/supl/asn-rrlp/BadSignalElement.c index 9069be966..5ed40b567 100644 --- a/src/core/libs/supl/asn-rrlp/BadSignalElement.c +++ b/src/core/libs/supl/asn-rrlp/BadSignalElement.c @@ -7,16 +7,16 @@ #include "BadSignalElement.h" static int memb_badSignalID_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,7 +30,7 @@ static int memb_badSignalID_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -43,14 +43,14 @@ static asn_per_constraints_t ASN_PER_MEMB_BAD_SIGNAL_ID_CONSTR_3 = { }; static asn_TYPE_member_t asn_MBR_BadSignalElement_1[] = { {ATF_NOFLAGS, 0, offsetof(struct BadSignalElement, badSVID), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SVID, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "badSVID"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SVID, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "badSVID"}, {ATF_POINTER, 1, offsetof(struct BadSignalElement, badSignalID), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_badSignalID_constraint_1, - &ASN_PER_MEMB_BAD_SIGNAL_ID_CONSTR_3, 0, "badSignalID"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_badSignalID_constraint_1, + &ASN_PER_MEMB_BAD_SIGNAL_ID_CONSTR_3, 0, "badSignalID"}, }; static int asn_MAP_BadSignalElement_oms_1[] = {1}; static ber_tlv_tag_t asn_DEF_BadSignalElement_tags_1[] = { @@ -89,7 +89,7 @@ asn_TYPE_descriptor_t asn_DEF_BadSignalElement = { asn_DEF_BadSignalElement_tags_1, /* Same as above */ sizeof(asn_DEF_BadSignalElement_tags_1) / sizeof(asn_DEF_BadSignalElement_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_BadSignalElement_1, 2, /* Elements count */ &asn_SPC_BadSignalElement_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/BitNumber.c b/src/core/libs/supl/asn-rrlp/BitNumber.c index 6cd0d5ff8..10253e46b 100644 --- a/src/core/libs/supl/asn-rrlp/BitNumber.c +++ b/src/core/libs/supl/asn-rrlp/BitNumber.c @@ -7,14 +7,14 @@ #include "BitNumber.h" int BitNumber_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int BitNumber_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -55,68 +55,68 @@ static void BitNumber_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void BitNumber_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { BitNumber_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int BitNumber_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { BitNumber_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t BitNumber_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, + int tag_mode) { BitNumber_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t BitNumber_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { BitNumber_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t BitNumber_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { BitNumber_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t BitNumber_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { BitNumber_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t BitNumber_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { BitNumber_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t BitNumber_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { BitNumber_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/CalcAssistanceBTS.c b/src/core/libs/supl/asn-rrlp/CalcAssistanceBTS.c index 00640c2ce..b84838611 100644 --- a/src/core/libs/supl/asn-rrlp/CalcAssistanceBTS.c +++ b/src/core/libs/supl/asn-rrlp/CalcAssistanceBTS.c @@ -8,16 +8,16 @@ static asn_TYPE_member_t asn_MBR_CalcAssistanceBTS_1[] = { {ATF_NOFLAGS, 0, offsetof(struct CalcAssistanceBTS, fineRTD), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_FineRTD, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "fineRTD"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_FineRTD, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "fineRTD"}, {ATF_NOFLAGS, 0, offsetof(struct CalcAssistanceBTS, referenceWGS84), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_ReferenceWGS84, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "referenceWGS84"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_ReferenceWGS84, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "referenceWGS84"}, }; static ber_tlv_tag_t asn_DEF_CalcAssistanceBTS_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -55,7 +55,7 @@ asn_TYPE_descriptor_t asn_DEF_CalcAssistanceBTS = { asn_DEF_CalcAssistanceBTS_tags_1, /* Same as above */ sizeof(asn_DEF_CalcAssistanceBTS_tags_1) / sizeof(asn_DEF_CalcAssistanceBTS_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_CalcAssistanceBTS_1, 2, /* Elements count */ &asn_SPC_CalcAssistanceBTS_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/CellID.c b/src/core/libs/supl/asn-rrlp/CellID.c index a2303c901..b0e162e75 100644 --- a/src/core/libs/supl/asn-rrlp/CellID.c +++ b/src/core/libs/supl/asn-rrlp/CellID.c @@ -7,14 +7,14 @@ #include "CellID.h" int CellID_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int CellID_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -61,60 +61,60 @@ void CellID_free(asn_TYPE_descriptor_t *td, void *struct_ptr, int contents_only) } int CellID_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { CellID_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t CellID_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, int tag_mode) { CellID_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t CellID_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { CellID_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t CellID_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { CellID_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t CellID_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { CellID_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t CellID_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { CellID_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t CellID_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { CellID_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); @@ -143,7 +143,7 @@ asn_TYPE_descriptor_t asn_DEF_CellID = { 0, /* Use generic outmost tag fetcher */ asn_DEF_CellID_tags_1, sizeof(asn_DEF_CellID_tags_1) / sizeof(asn_DEF_CellID_tags_1[0]), /* 1 */ - asn_DEF_CellID_tags_1, /* Same as above */ + asn_DEF_CellID_tags_1, /* Same as above */ sizeof(asn_DEF_CellID_tags_1) / sizeof(asn_DEF_CellID_tags_1[0]), /* 1 */ &ASN_PER_TYPE_CELL_ID_CONSTR_1, 0, diff --git a/src/core/libs/supl/asn-rrlp/CellIDAndLAC.c b/src/core/libs/supl/asn-rrlp/CellIDAndLAC.c index a68d71bbd..15e3d617a 100644 --- a/src/core/libs/supl/asn-rrlp/CellIDAndLAC.c +++ b/src/core/libs/supl/asn-rrlp/CellIDAndLAC.c @@ -8,15 +8,15 @@ static asn_TYPE_member_t asn_MBR_CellIDAndLAC_1[] = { {ATF_NOFLAGS, 0, offsetof(struct CellIDAndLAC, referenceLAC), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_LAC, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "referenceLAC"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_LAC, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "referenceLAC"}, {ATF_NOFLAGS, 0, offsetof(struct CellIDAndLAC, referenceCI), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_CellID, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "referenceCI"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_CellID, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "referenceCI"}, }; static ber_tlv_tag_t asn_DEF_CellIDAndLAC_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/CellIDAndLAC.h b/src/core/libs/supl/asn-rrlp/CellIDAndLAC.h index 4086737dc..ae344cd50 100644 --- a/src/core/libs/supl/asn-rrlp/CellIDAndLAC.h +++ b/src/core/libs/supl/asn-rrlp/CellIDAndLAC.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include "LAC.h" #include "CellID.h" +#include "LAC.h" #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/ControlHeader.c b/src/core/libs/supl/asn-rrlp/ControlHeader.c index 88acf8d33..4e156d05c 100644 --- a/src/core/libs/supl/asn-rrlp/ControlHeader.c +++ b/src/core/libs/supl/asn-rrlp/ControlHeader.c @@ -8,57 +8,57 @@ static asn_TYPE_member_t asn_MBR_ControlHeader_1[] = { {ATF_POINTER, 9, offsetof(struct ControlHeader, referenceTime), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_ReferenceTime, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "referenceTime"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_ReferenceTime, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "referenceTime"}, {ATF_POINTER, 8, offsetof(struct ControlHeader, refLocation), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_RefLocation, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "refLocation"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_RefLocation, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "refLocation"}, {ATF_POINTER, 7, offsetof(struct ControlHeader, dgpsCorrections), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_DGPSCorrections, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "dgpsCorrections"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_DGPSCorrections, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "dgpsCorrections"}, {ATF_POINTER, 6, offsetof(struct ControlHeader, navigationModel), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NavigationModel, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "navigationModel"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NavigationModel, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "navigationModel"}, {ATF_POINTER, 5, offsetof(struct ControlHeader, ionosphericModel), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_IonosphericModel, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ionosphericModel"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_IonosphericModel, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ionosphericModel"}, {ATF_POINTER, 4, offsetof(struct ControlHeader, utcModel), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_UTCModel, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "utcModel"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_UTCModel, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "utcModel"}, {ATF_POINTER, 3, offsetof(struct ControlHeader, almanac), - (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Almanac, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "almanac"}, + (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Almanac, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "almanac"}, {ATF_POINTER, 2, offsetof(struct ControlHeader, acquisAssist), - (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_AcquisAssist, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "acquisAssist"}, + (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_AcquisAssist, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "acquisAssist"}, {ATF_POINTER, 1, offsetof(struct ControlHeader, realTimeIntegrity), - (ASN_TAG_CLASS_CONTEXT | (8 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOf_BadSatelliteSet, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "realTimeIntegrity"}, + (ASN_TAG_CLASS_CONTEXT | (8 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOf_BadSatelliteSet, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "realTimeIntegrity"}, }; static int asn_MAP_ControlHeader_oms_1[] = {0, 1, 2, 3, 4, 5, 6, 7, 8}; static ber_tlv_tag_t asn_DEF_ControlHeader_tags_1[] = { @@ -72,7 +72,7 @@ static asn_TYPE_tag2member_t asn_MAP_ControlHeader_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (5 << 2)), 5, 0, 0}, /* utcModel at 579 */ {(ASN_TAG_CLASS_CONTEXT | (6 << 2)), 6, 0, 0}, /* almanac at 580 */ {(ASN_TAG_CLASS_CONTEXT | (7 << 2)), 7, 0, 0}, /* acquisAssist at 581 */ - {(ASN_TAG_CLASS_CONTEXT | (8 << 2)), 8, 0, 0} /* realTimeIntegrity at 582 */ + {(ASN_TAG_CLASS_CONTEXT | (8 << 2)), 8, 0, 0} /* realTimeIntegrity at 582 */ }; static asn_SEQUENCE_specifics_t asn_SPC_ControlHeader_specs_1 = { sizeof(struct ControlHeader), @@ -104,7 +104,7 @@ asn_TYPE_descriptor_t asn_DEF_ControlHeader = { asn_DEF_ControlHeader_tags_1, /* Same as above */ sizeof(asn_DEF_ControlHeader_tags_1) / sizeof(asn_DEF_ControlHeader_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_ControlHeader_1, 9, /* Elements count */ &asn_SPC_ControlHeader_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/ControlHeader.h b/src/core/libs/supl/asn-rrlp/ControlHeader.h index 208936b03..0f391db1b 100644 --- a/src/core/libs/supl/asn-rrlp/ControlHeader.h +++ b/src/core/libs/supl/asn-rrlp/ControlHeader.h @@ -53,15 +53,15 @@ extern "C" #endif /* Referred external types */ -#include "ReferenceTime.h" -#include "RefLocation.h" -#include "DGPSCorrections.h" -#include "NavigationModel.h" -#include "IonosphericModel.h" -#include "UTCModel.h" -#include "Almanac.h" #include "AcquisAssist.h" +#include "Almanac.h" +#include "DGPSCorrections.h" +#include "IonosphericModel.h" +#include "NavigationModel.h" +#include "RefLocation.h" +#include "ReferenceTime.h" #include "SeqOf-BadSatelliteSet.h" +#include "UTCModel.h" #endif /* _ControlHeader_H_ */ #include diff --git a/src/core/libs/supl/asn-rrlp/DGANSSSgnElement.c b/src/core/libs/supl/asn-rrlp/DGANSSSgnElement.c index dfb1c5d23..5dc9e01f4 100644 --- a/src/core/libs/supl/asn-rrlp/DGANSSSgnElement.c +++ b/src/core/libs/supl/asn-rrlp/DGANSSSgnElement.c @@ -7,15 +7,15 @@ #include "DGANSSSgnElement.h" static int memb_iod_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,21 +29,21 @@ static int memb_iod_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_udre_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -57,7 +57,7 @@ static int memb_udre_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -71,7 +71,7 @@ static int memb_pseudoRangeCor_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -85,22 +85,22 @@ static int memb_pseudoRangeCor_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_rangeRateCor_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -114,7 +114,7 @@ static int memb_rangeRateCor_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -145,26 +145,26 @@ static asn_per_constraints_t ASN_PER_MEMB_RANGE_RATE_COR_CONSTR_6 = { }; static asn_TYPE_member_t asn_MBR_DGANSSSgnElement_1[] = { {ATF_NOFLAGS, 0, offsetof(struct DGANSSSgnElement, svID), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SVID, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "svID"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SVID, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "svID"}, {ATF_NOFLAGS, 0, offsetof(struct DGANSSSgnElement, iod), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_iod_constraint_1, &ASN_PER_MEMB_IOD_CONSTR_3, - 0, "iod"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_iod_constraint_1, &ASN_PER_MEMB_IOD_CONSTR_3, + 0, "iod"}, {ATF_NOFLAGS, 0, offsetof(struct DGANSSSgnElement, udre), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_udre_constraint_1, - &ASN_PER_MEMB_UDRE_CONSTR_4, 0, "udre"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_udre_constraint_1, + &ASN_PER_MEMB_UDRE_CONSTR_4, 0, "udre"}, {ATF_NOFLAGS, 0, offsetof(struct DGANSSSgnElement, pseudoRangeCor), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_pseudoRangeCor_constraint_1, - &ASN_PER_MEMB_PSEUDO_RANGE_COR_CONSTR_5, 0, "pseudoRangeCor"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_pseudoRangeCor_constraint_1, + &ASN_PER_MEMB_PSEUDO_RANGE_COR_CONSTR_5, 0, "pseudoRangeCor"}, {ATF_NOFLAGS, 0, offsetof(struct DGANSSSgnElement, rangeRateCor), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_rangeRateCor_constraint_1, - &ASN_PER_MEMB_RANGE_RATE_COR_CONSTR_6, 0, "rangeRateCor"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_rangeRateCor_constraint_1, + &ASN_PER_MEMB_RANGE_RATE_COR_CONSTR_6, 0, "rangeRateCor"}, }; static ber_tlv_tag_t asn_DEF_DGANSSSgnElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -205,7 +205,7 @@ asn_TYPE_descriptor_t asn_DEF_DGANSSSgnElement = { asn_DEF_DGANSSSgnElement_tags_1, /* Same as above */ sizeof(asn_DEF_DGANSSSgnElement_tags_1) / sizeof(asn_DEF_DGANSSSgnElement_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_DGANSSSgnElement_1, 5, /* Elements count */ &asn_SPC_DGANSSSgnElement_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/DGPSCorrections.c b/src/core/libs/supl/asn-rrlp/DGPSCorrections.c index e1fa3d555..56f96c97e 100644 --- a/src/core/libs/supl/asn-rrlp/DGPSCorrections.c +++ b/src/core/libs/supl/asn-rrlp/DGPSCorrections.c @@ -7,15 +7,15 @@ #include "DGPSCorrections.h" static int memb_gpsTOW_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,21 +29,21 @@ static int memb_gpsTOW_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_status_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -57,7 +57,7 @@ static int memb_status_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -76,19 +76,19 @@ static asn_per_constraints_t ASN_PER_MEMB_STATUS_CONSTR_3 = { }; static asn_TYPE_member_t asn_MBR_DGPSCorrections_1[] = { {ATF_NOFLAGS, 0, offsetof(struct DGPSCorrections, gpsTOW), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_gpsTOW_constraint_1, - &ASN_PER_MEMB_GPS_TOW_CONSTR_2, 0, "gpsTOW"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_gpsTOW_constraint_1, + &ASN_PER_MEMB_GPS_TOW_CONSTR_2, 0, "gpsTOW"}, {ATF_NOFLAGS, 0, offsetof(struct DGPSCorrections, status), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_status_constraint_1, - &ASN_PER_MEMB_STATUS_CONSTR_3, 0, "status"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_status_constraint_1, + &ASN_PER_MEMB_STATUS_CONSTR_3, 0, "status"}, {ATF_NOFLAGS, 0, offsetof(struct DGPSCorrections, satList), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfSatElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "satList"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfSatElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "satList"}, }; static ber_tlv_tag_t asn_DEF_DGPSCorrections_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -127,7 +127,7 @@ asn_TYPE_descriptor_t asn_DEF_DGPSCorrections = { asn_DEF_DGPSCorrections_tags_1, /* Same as above */ sizeof(asn_DEF_DGPSCorrections_tags_1) / sizeof(asn_DEF_DGPSCorrections_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_DGPSCorrections_1, 3, /* Elements count */ &asn_SPC_DGPSCorrections_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/DGPSCorrections.h b/src/core/libs/supl/asn-rrlp/DGPSCorrections.h index 7f4e69151..2ee4ed3f7 100644 --- a/src/core/libs/supl/asn-rrlp/DGPSCorrections.h +++ b/src/core/libs/supl/asn-rrlp/DGPSCorrections.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include #include "SeqOfSatElement.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/ENUMERATED.c b/src/core/libs/supl/asn-rrlp/ENUMERATED.c index b41f70a42..dd0d13d9b 100644 --- a/src/core/libs/supl/asn-rrlp/ENUMERATED.c +++ b/src/core/libs/supl/asn-rrlp/ENUMERATED.c @@ -3,10 +3,10 @@ * All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ -#include #include #include #include /* Encoder and decoder of a primitive type */ +#include /* * ENUMERATED basic type description. @@ -37,9 +37,9 @@ asn_TYPE_descriptor_t asn_DEF_ENUMERATED = { }; asn_dec_rval_t ENUMERATED_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd) { asn_dec_rval_t rval; ENUMERATED_t *st = (ENUMERATED_t *)*sptr; @@ -60,8 +60,8 @@ asn_dec_rval_t ENUMERATED_decode_uper(asn_codec_ctx_t *opt_codec_ctx, } asn_enc_rval_t ENUMERATED_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *sptr, asn_per_outp_t *po) + asn_per_constraints_t *constraints, + void *sptr, asn_per_outp_t *po) { ENUMERATED_t *st = (ENUMERATED_t *)sptr; int64_t value; diff --git a/src/core/libs/supl/asn-rrlp/EOTDQuality.c b/src/core/libs/supl/asn-rrlp/EOTDQuality.c index 7fe565c54..0e1531d26 100644 --- a/src/core/libs/supl/asn-rrlp/EOTDQuality.c +++ b/src/core/libs/supl/asn-rrlp/EOTDQuality.c @@ -15,7 +15,7 @@ static int memb_nbrOfMeasurements_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,22 +29,22 @@ static int memb_nbrOfMeasurements_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_stdOfEOTD_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -58,7 +58,7 @@ static int memb_stdOfEOTD_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -77,19 +77,19 @@ static asn_per_constraints_t ASN_PER_MEMB_STD_OF_EOTD_CONSTR_3 = { }; static asn_TYPE_member_t asn_MBR_EOTDQuality_1[] = { {ATF_NOFLAGS, 0, offsetof(struct EOTDQuality, nbrOfMeasurements), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_nbrOfMeasurements_constraint_1, - &ASN_PER_MEMB_NBR_OF_MEASUREMENTS_CONSTR_2, 0, "nbrOfMeasurements"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_nbrOfMeasurements_constraint_1, + &ASN_PER_MEMB_NBR_OF_MEASUREMENTS_CONSTR_2, 0, "nbrOfMeasurements"}, {ATF_NOFLAGS, 0, offsetof(struct EOTDQuality, stdOfEOTD), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_stdOfEOTD_constraint_1, - &ASN_PER_MEMB_STD_OF_EOTD_CONSTR_3, 0, "stdOfEOTD"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_stdOfEOTD_constraint_1, + &ASN_PER_MEMB_STD_OF_EOTD_CONSTR_3, 0, "stdOfEOTD"}, }; static ber_tlv_tag_t asn_DEF_EOTDQuality_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_EOTDQuality_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0}, /* nbrOfMeasurements at 393 */ + 0}, /* nbrOfMeasurements at 393 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0} /* stdOfEOTD at 394 */ }; static asn_SEQUENCE_specifics_t asn_SPC_EOTDQuality_specs_1 = { diff --git a/src/core/libs/supl/asn-rrlp/EnvironmentCharacter.c b/src/core/libs/supl/asn-rrlp/EnvironmentCharacter.c index d5012ab1b..092656bd2 100644 --- a/src/core/libs/supl/asn-rrlp/EnvironmentCharacter.c +++ b/src/core/libs/supl/asn-rrlp/EnvironmentCharacter.c @@ -7,8 +7,8 @@ #include "EnvironmentCharacter.h" int EnvironmentCharacter_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { /* Replace with underlying type checker */ td->check_constraints = asn_DEF_ENUMERATED.check_constraints; @@ -40,57 +40,57 @@ static void EnvironmentCharacter_1_inherit_TYPE_descriptor( } void EnvironmentCharacter_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { EnvironmentCharacter_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int EnvironmentCharacter_print(asn_TYPE_descriptor_t *td, - const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + const void *struct_ptr, int ilevel, + asn_app_consume_bytes_f *cb, void *app_key) { EnvironmentCharacter_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t EnvironmentCharacter_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, + const void *bufptr, size_t size, + int tag_mode) { EnvironmentCharacter_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t EnvironmentCharacter_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { EnvironmentCharacter_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t EnvironmentCharacter_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { EnvironmentCharacter_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t EnvironmentCharacter_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { EnvironmentCharacter_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); @@ -103,7 +103,7 @@ asn_dec_rval_t EnvironmentCharacter_decode_uper( { EnvironmentCharacter_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t EnvironmentCharacter_encode_uper( @@ -133,10 +133,10 @@ static unsigned int asn_MAP_EnvironmentCharacter_enum2value_1[] = { static asn_INTEGER_specifics_t asn_SPC_EnvironmentCharacter_specs_1 = { asn_MAP_EnvironmentCharacter_value2enum_1, /* "tag" => N; sorted by tag */ asn_MAP_EnvironmentCharacter_enum2value_1, /* N => "tag"; sorted by N */ - 3, /* Number of elements in the maps */ - 4, /* Extensions before this member */ - 1, /* Strict enumeration */ - 0, /* Native long size */ + 3, /* Number of elements in the maps */ + 4, /* Extensions before this member */ + 1, /* Strict enumeration */ + 0, /* Native long size */ 0}; static ber_tlv_tag_t asn_DEF_EnvironmentCharacter_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (10 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/EphemerisSubframe1Reserved.c b/src/core/libs/supl/asn-rrlp/EphemerisSubframe1Reserved.c index d73e4bb51..8055baf17 100644 --- a/src/core/libs/supl/asn-rrlp/EphemerisSubframe1Reserved.c +++ b/src/core/libs/supl/asn-rrlp/EphemerisSubframe1Reserved.c @@ -7,16 +7,16 @@ #include "EphemerisSubframe1Reserved.h" static int memb_reserved1_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,22 +30,22 @@ static int memb_reserved1_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_reserved2_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -59,22 +59,22 @@ static int memb_reserved2_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_reserved3_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -88,22 +88,22 @@ static int memb_reserved3_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_reserved4_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -117,7 +117,7 @@ static int memb_reserved4_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -148,21 +148,21 @@ static asn_per_constraints_t ASN_PER_MEMB_RESERVED4_CONSTR_5 = { }; static asn_TYPE_member_t asn_MBR_EphemerisSubframe1Reserved_1[] = { {ATF_NOFLAGS, 0, offsetof(struct EphemerisSubframe1Reserved, reserved1), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_reserved1_constraint_1, - &ASN_PER_MEMB_RESERVED1_CONSTR_2, 0, "reserved1"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_reserved1_constraint_1, + &ASN_PER_MEMB_RESERVED1_CONSTR_2, 0, "reserved1"}, {ATF_NOFLAGS, 0, offsetof(struct EphemerisSubframe1Reserved, reserved2), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_reserved2_constraint_1, - &ASN_PER_MEMB_RESERVED2_CONSTR_3, 0, "reserved2"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_reserved2_constraint_1, + &ASN_PER_MEMB_RESERVED2_CONSTR_3, 0, "reserved2"}, {ATF_NOFLAGS, 0, offsetof(struct EphemerisSubframe1Reserved, reserved3), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_reserved3_constraint_1, - &ASN_PER_MEMB_RESERVED3_CONSTR_4, 0, "reserved3"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_reserved3_constraint_1, + &ASN_PER_MEMB_RESERVED3_CONSTR_4, 0, "reserved3"}, {ATF_NOFLAGS, 0, offsetof(struct EphemerisSubframe1Reserved, reserved4), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_reserved4_constraint_1, - &ASN_PER_MEMB_RESERVED4_CONSTR_5, 0, "reserved4"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_reserved4_constraint_1, + &ASN_PER_MEMB_RESERVED4_CONSTR_5, 0, "reserved4"}, }; static ber_tlv_tag_t asn_DEF_EphemerisSubframe1Reserved_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -199,10 +199,10 @@ asn_TYPE_descriptor_t asn_DEF_EphemerisSubframe1Reserved = { asn_DEF_EphemerisSubframe1Reserved_tags_1, sizeof(asn_DEF_EphemerisSubframe1Reserved_tags_1) / sizeof(asn_DEF_EphemerisSubframe1Reserved_tags_1[0]), /* 1 */ - asn_DEF_EphemerisSubframe1Reserved_tags_1, /* Same as above */ + asn_DEF_EphemerisSubframe1Reserved_tags_1, /* Same as above */ sizeof(asn_DEF_EphemerisSubframe1Reserved_tags_1) / sizeof(asn_DEF_EphemerisSubframe1Reserved_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_EphemerisSubframe1Reserved_1, 4, /* Elements count */ &asn_SPC_EphemerisSubframe1Reserved_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/ErrorCodes.c b/src/core/libs/supl/asn-rrlp/ErrorCodes.c index 37819dadf..5582fb4af 100644 --- a/src/core/libs/supl/asn-rrlp/ErrorCodes.c +++ b/src/core/libs/supl/asn-rrlp/ErrorCodes.c @@ -7,7 +7,7 @@ #include "ErrorCodes.h" int ErrorCodes_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { /* Replace with underlying type checker */ td->check_constraints = asn_DEF_ENUMERATED.check_constraints; @@ -38,69 +38,69 @@ static void ErrorCodes_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void ErrorCodes_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { ErrorCodes_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int ErrorCodes_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { ErrorCodes_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t ErrorCodes_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { ErrorCodes_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t ErrorCodes_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { ErrorCodes_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t ErrorCodes_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, const char *opt_mname, + const void *bufptr, size_t size) { ErrorCodes_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t ErrorCodes_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { ErrorCodes_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t ErrorCodes_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { ErrorCodes_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t ErrorCodes_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { ErrorCodes_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/ExpOTDUncertainty.c b/src/core/libs/supl/asn-rrlp/ExpOTDUncertainty.c index e37e3df44..617450919 100644 --- a/src/core/libs/supl/asn-rrlp/ExpOTDUncertainty.c +++ b/src/core/libs/supl/asn-rrlp/ExpOTDUncertainty.c @@ -7,15 +7,15 @@ #include "ExpOTDUncertainty.h" int ExpOTDUncertainty_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ int ExpOTDUncertainty_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -57,77 +57,77 @@ static void ExpOTDUncertainty_1_inherit_TYPE_descriptor( } void ExpOTDUncertainty_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { ExpOTDUncertainty_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int ExpOTDUncertainty_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, + void *app_key) { ExpOTDUncertainty_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t ExpOTDUncertainty_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, + const void *bufptr, size_t size, + int tag_mode) { ExpOTDUncertainty_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t ExpOTDUncertainty_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { ExpOTDUncertainty_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t ExpOTDUncertainty_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { ExpOTDUncertainty_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t ExpOTDUncertainty_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { ExpOTDUncertainty_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t ExpOTDUncertainty_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { ExpOTDUncertainty_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t ExpOTDUncertainty_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { ExpOTDUncertainty_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/ExpectedOTD.c b/src/core/libs/supl/asn-rrlp/ExpectedOTD.c index 9f18a2fe4..152f976f2 100644 --- a/src/core/libs/supl/asn-rrlp/ExpectedOTD.c +++ b/src/core/libs/supl/asn-rrlp/ExpectedOTD.c @@ -7,14 +7,14 @@ #include "ExpectedOTD.h" int ExpectedOTD_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int ExpectedOTD_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -55,73 +55,73 @@ static void ExpectedOTD_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void ExpectedOTD_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { ExpectedOTD_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int ExpectedOTD_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { ExpectedOTD_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t ExpectedOTD_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { ExpectedOTD_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t ExpectedOTD_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { ExpectedOTD_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t ExpectedOTD_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, const char *opt_mname, + const void *bufptr, size_t size) { ExpectedOTD_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t ExpectedOTD_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { ExpectedOTD_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t ExpectedOTD_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { ExpectedOTD_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t ExpectedOTD_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { ExpectedOTD_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/Ext-GeographicalInformation.c b/src/core/libs/supl/asn-rrlp/Ext-GeographicalInformation.c index 0db12f144..bb5c9c777 100644 --- a/src/core/libs/supl/asn-rrlp/Ext-GeographicalInformation.c +++ b/src/core/libs/supl/asn-rrlp/Ext-GeographicalInformation.c @@ -16,7 +16,7 @@ int Ext_GeographicalInformation_constraint( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,7 +30,7 @@ int Ext_GeographicalInformation_constraint( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -58,16 +58,16 @@ static void Ext_GeographicalInformation_1_inherit_TYPE_descriptor( } void Ext_GeographicalInformation_free(asn_TYPE_descriptor_t *td, - void *struct_ptr, int contents_only) + void *struct_ptr, int contents_only) { Ext_GeographicalInformation_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int Ext_GeographicalInformation_print(asn_TYPE_descriptor_t *td, - const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, - void *app_key) + const void *struct_ptr, int ilevel, + asn_app_consume_bytes_f *cb, + void *app_key) { Ext_GeographicalInformation_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); @@ -79,7 +79,7 @@ asn_dec_rval_t Ext_GeographicalInformation_decode_ber( { Ext_GeographicalInformation_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t Ext_GeographicalInformation_encode_der( @@ -96,7 +96,7 @@ asn_dec_rval_t Ext_GeographicalInformation_decode_xer( { Ext_GeographicalInformation_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t Ext_GeographicalInformation_encode_xer( @@ -114,7 +114,7 @@ asn_dec_rval_t Ext_GeographicalInformation_decode_uper( { Ext_GeographicalInformation_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t Ext_GeographicalInformation_encode_uper( @@ -150,7 +150,7 @@ asn_TYPE_descriptor_t asn_DEF_Ext_GeographicalInformation = { asn_DEF_Ext_GeographicalInformation_tags_1, sizeof(asn_DEF_Ext_GeographicalInformation_tags_1) / sizeof(asn_DEF_Ext_GeographicalInformation_tags_1[0]), /* 1 */ - asn_DEF_Ext_GeographicalInformation_tags_1, /* Same as above */ + asn_DEF_Ext_GeographicalInformation_tags_1, /* Same as above */ sizeof(asn_DEF_Ext_GeographicalInformation_tags_1) / sizeof(asn_DEF_Ext_GeographicalInformation_tags_1[0]), /* 1 */ &ASN_PER_TYPE_EXT_GEOGRAPHICAL_INFORMATION_CONSTR_1, diff --git a/src/core/libs/supl/asn-rrlp/Extended-reference.c b/src/core/libs/supl/asn-rrlp/Extended-reference.c index 71ec54c0d..88218c849 100644 --- a/src/core/libs/supl/asn-rrlp/Extended-reference.c +++ b/src/core/libs/supl/asn-rrlp/Extended-reference.c @@ -7,16 +7,16 @@ #include "Extended-reference.h" static int memb_smlc_code_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,7 +30,7 @@ static int memb_smlc_code_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -44,7 +44,7 @@ static int memb_transaction_ID_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -58,7 +58,7 @@ static int memb_transaction_ID_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -77,13 +77,13 @@ static asn_per_constraints_t ASN_PER_MEMB_TRANSACTION_ID_CONSTR_3 = { }; static asn_TYPE_member_t asn_MBR_Extended_reference_1[] = { {ATF_NOFLAGS, 0, offsetof(struct Extended_reference, smlc_code), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_smlc_code_constraint_1, - &ASN_PER_MEMB_SMLC_CODE_CONSTR_2, 0, "smlc-code"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_smlc_code_constraint_1, + &ASN_PER_MEMB_SMLC_CODE_CONSTR_2, 0, "smlc-code"}, {ATF_NOFLAGS, 0, offsetof(struct Extended_reference, transaction_ID), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_transaction_ID_constraint_1, - &ASN_PER_MEMB_TRANSACTION_ID_CONSTR_3, 0, "transaction-ID"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_transaction_ID_constraint_1, + &ASN_PER_MEMB_TRANSACTION_ID_CONSTR_3, 0, "transaction-ID"}, }; static ber_tlv_tag_t asn_DEF_Extended_reference_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -121,7 +121,7 @@ asn_TYPE_descriptor_t asn_DEF_Extended_reference = { asn_DEF_Extended_reference_tags_1, /* Same as above */ sizeof(asn_DEF_Extended_reference_tags_1) / sizeof(asn_DEF_Extended_reference_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_Extended_reference_1, 2, /* Elements count */ &asn_SPC_Extended_reference_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/ExtensionContainer.c b/src/core/libs/supl/asn-rrlp/ExtensionContainer.c index d24b49255..5a58a53c1 100644 --- a/src/core/libs/supl/asn-rrlp/ExtensionContainer.c +++ b/src/core/libs/supl/asn-rrlp/ExtensionContainer.c @@ -7,8 +7,8 @@ #include "ExtensionContainer.h" int ExtensionContainer_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { /* Replace with underlying type checker */ td->check_constraints = asn_DEF_INTEGER.check_constraints; @@ -38,57 +38,57 @@ static void ExtensionContainer_1_inherit_TYPE_descriptor( } void ExtensionContainer_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { ExtensionContainer_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int ExtensionContainer_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, + void *app_key) { ExtensionContainer_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t ExtensionContainer_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, + const void *bufptr, size_t size, + int tag_mode) { ExtensionContainer_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t ExtensionContainer_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { ExtensionContainer_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t ExtensionContainer_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { ExtensionContainer_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t ExtensionContainer_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { ExtensionContainer_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); @@ -101,7 +101,7 @@ asn_dec_rval_t ExtensionContainer_decode_uper( { ExtensionContainer_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t ExtensionContainer_encode_uper( @@ -133,7 +133,7 @@ asn_TYPE_descriptor_t asn_DEF_ExtensionContainer = { asn_DEF_ExtensionContainer_tags_1, /* Same as above */ sizeof(asn_DEF_ExtensionContainer_tags_1) / sizeof(asn_DEF_ExtensionContainer_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ 0, 0, /* No members */ 0 /* No specifics */ diff --git a/src/core/libs/supl/asn-rrlp/FineRTD.c b/src/core/libs/supl/asn-rrlp/FineRTD.c index 6beb1abdb..59b17e338 100644 --- a/src/core/libs/supl/asn-rrlp/FineRTD.c +++ b/src/core/libs/supl/asn-rrlp/FineRTD.c @@ -7,14 +7,14 @@ #include "FineRTD.h" int FineRTD_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int FineRTD_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -55,67 +55,67 @@ static void FineRTD_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void FineRTD_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { FineRTD_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int FineRTD_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { FineRTD_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t FineRTD_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, int tag_mode) { FineRTD_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t FineRTD_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { FineRTD_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t FineRTD_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { FineRTD_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t FineRTD_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { FineRTD_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t FineRTD_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { FineRTD_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t FineRTD_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { FineRTD_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); @@ -144,7 +144,7 @@ asn_TYPE_descriptor_t asn_DEF_FineRTD = { 0, /* Use generic outmost tag fetcher */ asn_DEF_FineRTD_tags_1, sizeof(asn_DEF_FineRTD_tags_1) / sizeof(asn_DEF_FineRTD_tags_1[0]), /* 1 */ - asn_DEF_FineRTD_tags_1, /* Same as above */ + asn_DEF_FineRTD_tags_1, /* Same as above */ sizeof(asn_DEF_FineRTD_tags_1) / sizeof(asn_DEF_FineRTD_tags_1[0]), /* 1 */ &ASN_PER_TYPE_FINE_RTD_CONSTR_1, 0, diff --git a/src/core/libs/supl/asn-rrlp/FixType.c b/src/core/libs/supl/asn-rrlp/FixType.c index cd73f76d7..224e42b5c 100644 --- a/src/core/libs/supl/asn-rrlp/FixType.c +++ b/src/core/libs/supl/asn-rrlp/FixType.c @@ -7,14 +7,14 @@ #include "FixType.h" int FixType_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int FixType_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -55,67 +55,67 @@ static void FixType_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void FixType_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { FixType_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int FixType_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { FixType_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t FixType_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, int tag_mode) { FixType_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t FixType_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { FixType_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t FixType_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { FixType_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t FixType_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { FixType_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t FixType_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { FixType_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t FixType_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { FixType_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); @@ -144,7 +144,7 @@ asn_TYPE_descriptor_t asn_DEF_FixType = { 0, /* Use generic outmost tag fetcher */ asn_DEF_FixType_tags_1, sizeof(asn_DEF_FixType_tags_1) / sizeof(asn_DEF_FixType_tags_1[0]), /* 1 */ - asn_DEF_FixType_tags_1, /* Same as above */ + asn_DEF_FixType_tags_1, /* Same as above */ sizeof(asn_DEF_FixType_tags_1) / sizeof(asn_DEF_FixType_tags_1[0]), /* 1 */ &ASN_PER_TYPE_FIX_TYPE_CONSTR_1, 0, diff --git a/src/core/libs/supl/asn-rrlp/FrameDrift.c b/src/core/libs/supl/asn-rrlp/FrameDrift.c index d5f72e0ab..769fce79f 100644 --- a/src/core/libs/supl/asn-rrlp/FrameDrift.c +++ b/src/core/libs/supl/asn-rrlp/FrameDrift.c @@ -7,14 +7,14 @@ #include "FrameDrift.h" int FrameDrift_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int FrameDrift_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -55,69 +55,69 @@ static void FrameDrift_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void FrameDrift_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { FrameDrift_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int FrameDrift_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { FrameDrift_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t FrameDrift_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { FrameDrift_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t FrameDrift_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { FrameDrift_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t FrameDrift_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, const char *opt_mname, + const void *bufptr, size_t size) { FrameDrift_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t FrameDrift_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { FrameDrift_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t FrameDrift_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { FrameDrift_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t FrameDrift_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { FrameDrift_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/FrameNumber.c b/src/core/libs/supl/asn-rrlp/FrameNumber.c index 5381f28c6..607ac1561 100644 --- a/src/core/libs/supl/asn-rrlp/FrameNumber.c +++ b/src/core/libs/supl/asn-rrlp/FrameNumber.c @@ -7,14 +7,14 @@ #include "FrameNumber.h" int FrameNumber_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int FrameNumber_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -55,73 +55,73 @@ static void FrameNumber_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void FrameNumber_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { FrameNumber_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int FrameNumber_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { FrameNumber_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t FrameNumber_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { FrameNumber_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t FrameNumber_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { FrameNumber_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t FrameNumber_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, const char *opt_mname, + const void *bufptr, size_t size) { FrameNumber_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t FrameNumber_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { FrameNumber_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t FrameNumber_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { FrameNumber_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t FrameNumber_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { FrameNumber_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/GANSS-AssistData.c b/src/core/libs/supl/asn-rrlp/GANSS-AssistData.c index 35c7f983b..b20bfab97 100644 --- a/src/core/libs/supl/asn-rrlp/GANSS-AssistData.c +++ b/src/core/libs/supl/asn-rrlp/GANSS-AssistData.c @@ -8,17 +8,17 @@ static asn_TYPE_member_t asn_MBR_GANSS_AssistData_1[] = { {ATF_NOFLAGS, 0, offsetof(struct GANSS_AssistData, ganss_controlHeader), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSS_ControlHeader, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganss-controlHeader"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSS_ControlHeader, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganss-controlHeader"}, }; static ber_tlv_tag_t asn_DEF_GANSS_AssistData_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_GANSS_AssistData_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0} /* ganss-controlHeader at 1062 */ + 0} /* ganss-controlHeader at 1062 */ }; static asn_SEQUENCE_specifics_t asn_SPC_GANSS_AssistData_specs_1 = { sizeof(struct GANSS_AssistData), @@ -50,7 +50,7 @@ asn_TYPE_descriptor_t asn_DEF_GANSS_AssistData = { asn_DEF_GANSS_AssistData_tags_1, /* Same as above */ sizeof(asn_DEF_GANSS_AssistData_tags_1) / sizeof(asn_DEF_GANSS_AssistData_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSS_AssistData_1, 1, /* Elements count */ &asn_SPC_GANSS_AssistData_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GANSS-ControlHeader.c b/src/core/libs/supl/asn-rrlp/GANSS-ControlHeader.c index a7f2d2fe6..fe0cc94e4 100644 --- a/src/core/libs/supl/asn-rrlp/GANSS-ControlHeader.c +++ b/src/core/libs/supl/asn-rrlp/GANSS-ControlHeader.c @@ -8,28 +8,28 @@ static asn_TYPE_member_t asn_MBR_GANSS_ControlHeader_1[] = { {ATF_POINTER, 2, - offsetof(struct GANSS_ControlHeader, ganssCommonAssistData), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSCommonAssistData, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssCommonAssistData"}, + offsetof(struct GANSS_ControlHeader, ganssCommonAssistData), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSCommonAssistData, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssCommonAssistData"}, {ATF_POINTER, 1, - offsetof(struct GANSS_ControlHeader, ganssGenericAssistDataList), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfGANSSGenericAssistDataElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssGenericAssistDataList"}, + offsetof(struct GANSS_ControlHeader, ganssGenericAssistDataList), + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfGANSSGenericAssistDataElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssGenericAssistDataList"}, }; static int asn_MAP_GANSS_ControlHeader_oms_1[] = {0, 1}; static ber_tlv_tag_t asn_DEF_GANSS_ControlHeader_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_GANSS_ControlHeader_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0}, /* ganssCommonAssistData at 1065 */ + 0}, /* ganssCommonAssistData at 1065 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0} /* ganssGenericAssistDataList at 1066 */ + 0} /* ganssGenericAssistDataList at 1066 */ }; static asn_SEQUENCE_specifics_t asn_SPC_GANSS_ControlHeader_specs_1 = { sizeof(struct GANSS_ControlHeader), @@ -61,7 +61,7 @@ asn_TYPE_descriptor_t asn_DEF_GANSS_ControlHeader = { asn_DEF_GANSS_ControlHeader_tags_1, /* Same as above */ sizeof(asn_DEF_GANSS_ControlHeader_tags_1) / sizeof(asn_DEF_GANSS_ControlHeader_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSS_ControlHeader_1, 2, /* Elements count */ &asn_SPC_GANSS_ControlHeader_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GANSS-MsrSetElement.c b/src/core/libs/supl/asn-rrlp/GANSS-MsrSetElement.c index 770d5a5fe..8406aa0e7 100644 --- a/src/core/libs/supl/asn-rrlp/GANSS-MsrSetElement.c +++ b/src/core/libs/supl/asn-rrlp/GANSS-MsrSetElement.c @@ -15,7 +15,7 @@ static int memb_deltaGNASSTOD_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ static int memb_deltaGNASSTOD_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -42,32 +42,32 @@ static asn_per_constraints_t ASN_PER_MEMB_DELTA_GNASSTOD_CONSTR_4 = { }; static asn_TYPE_member_t asn_MBR_GANSS_MsrSetElement_1[] = { {ATF_POINTER, 4, offsetof(struct GANSS_MsrSetElement, referenceFrame), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_ReferenceFrame, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "referenceFrame"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_ReferenceFrame, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "referenceFrame"}, {ATF_POINTER, 3, offsetof(struct GANSS_MsrSetElement, ganssTODm), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSTODm, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssTODm"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSTODm, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssTODm"}, {ATF_POINTER, 2, offsetof(struct GANSS_MsrSetElement, deltaGNASSTOD), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_deltaGNASSTOD_constraint_1, - &ASN_PER_MEMB_DELTA_GNASSTOD_CONSTR_4, 0, "deltaGNASSTOD"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_deltaGNASSTOD_constraint_1, + &ASN_PER_MEMB_DELTA_GNASSTOD_CONSTR_4, 0, "deltaGNASSTOD"}, {ATF_POINTER, 1, offsetof(struct GANSS_MsrSetElement, ganssTODUncertainty), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSTODUncertainty, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssTODUncertainty"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSTODUncertainty, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssTODUncertainty"}, {ATF_NOFLAGS, 0, offsetof(struct GANSS_MsrSetElement, ganss_SgnTypeList), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfGANSS_SgnTypeElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganss-SgnTypeList"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfGANSS_SgnTypeElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganss-SgnTypeList"}, }; static int asn_MAP_GANSS_MsrSetElement_oms_1[] = {0, 1, 2, 3}; static ber_tlv_tag_t asn_DEF_GANSS_MsrSetElement_tags_1[] = { @@ -77,9 +77,9 @@ static asn_TYPE_tag2member_t asn_MAP_GANSS_MsrSetElement_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0}, /* ganssTODm at 1457 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0}, /* deltaGNASSTOD at 1458 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, - 0}, /* ganssTODUncertainty at 1459 */ + 0}, /* ganssTODUncertainty at 1459 */ {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, - 0} /* ganss-SgnTypeList at 1463 */ + 0} /* ganss-SgnTypeList at 1463 */ }; static asn_SEQUENCE_specifics_t asn_SPC_GANSS_MsrSetElement_specs_1 = { sizeof(struct GANSS_MsrSetElement), @@ -111,7 +111,7 @@ asn_TYPE_descriptor_t asn_DEF_GANSS_MsrSetElement = { asn_DEF_GANSS_MsrSetElement_tags_1, /* Same as above */ sizeof(asn_DEF_GANSS_MsrSetElement_tags_1) / sizeof(asn_DEF_GANSS_MsrSetElement_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSS_MsrSetElement_1, 5, /* Elements count */ &asn_SPC_GANSS_MsrSetElement_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GANSS-MsrSetElement.h b/src/core/libs/supl/asn-rrlp/GANSS-MsrSetElement.h index 2b746f809..9e24d4ff5 100644 --- a/src/core/libs/supl/asn-rrlp/GANSS-MsrSetElement.h +++ b/src/core/libs/supl/asn-rrlp/GANSS-MsrSetElement.h @@ -10,10 +10,10 @@ #include /* Including external dependencies */ -#include "GANSSTODm.h" -#include #include "GANSSTODUncertainty.h" +#include "GANSSTODm.h" #include "SeqOfGANSS-SgnTypeElement.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/GANSS-SgnElement.c b/src/core/libs/supl/asn-rrlp/GANSS-SgnElement.c index f83bc6b87..e8b7c5f62 100644 --- a/src/core/libs/supl/asn-rrlp/GANSS-SgnElement.c +++ b/src/core/libs/supl/asn-rrlp/GANSS-SgnElement.c @@ -7,15 +7,15 @@ #include "GANSS-SgnElement.h" static int memb_cNo_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ static int memb_cNo_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -43,7 +43,7 @@ static int memb_carrierQualityInd_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -57,22 +57,22 @@ static int memb_carrierQualityInd_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_codePhase_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -86,7 +86,7 @@ static int memb_codePhase_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -100,7 +100,7 @@ static int memb_integerCodePhase_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -114,7 +114,7 @@ static int memb_integerCodePhase_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -128,7 +128,7 @@ static int memb_codePhaseRMSError_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -142,22 +142,22 @@ static int memb_codePhaseRMSError_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_doppler_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -171,21 +171,21 @@ static int memb_doppler_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_adr_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -199,7 +199,7 @@ static int memb_adr_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -248,43 +248,43 @@ static asn_per_constraints_t ASN_PER_MEMB_ADR_CONSTR_10 = { }; static asn_TYPE_member_t asn_MBR_GANSS_SgnElement_1[] = { {ATF_NOFLAGS, 0, offsetof(struct GANSS_SgnElement, svID), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SVID, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "svID"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SVID, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "svID"}, {ATF_NOFLAGS, 0, offsetof(struct GANSS_SgnElement, cNo), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_cNo_constraint_1, &ASN_PER_MEMB_C_NO_CONSTR_3, - 0, "cNo"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_cNo_constraint_1, &ASN_PER_MEMB_C_NO_CONSTR_3, + 0, "cNo"}, {ATF_NOFLAGS, 0, offsetof(struct GANSS_SgnElement, mpathDet), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_MpathIndic, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "mpathDet"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_MpathIndic, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "mpathDet"}, {ATF_POINTER, 1, offsetof(struct GANSS_SgnElement, carrierQualityInd), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_carrierQualityInd_constraint_1, - &ASN_PER_MEMB_CARRIER_QUALITY_IND_CONSTR_5, 0, "carrierQualityInd"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_carrierQualityInd_constraint_1, + &ASN_PER_MEMB_CARRIER_QUALITY_IND_CONSTR_5, 0, "carrierQualityInd"}, {ATF_NOFLAGS, 0, offsetof(struct GANSS_SgnElement, codePhase), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_codePhase_constraint_1, - &ASN_PER_MEMB_CODE_PHASE_CONSTR_6, 0, "codePhase"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_codePhase_constraint_1, + &ASN_PER_MEMB_CODE_PHASE_CONSTR_6, 0, "codePhase"}, {ATF_POINTER, 1, offsetof(struct GANSS_SgnElement, integerCodePhase), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_integerCodePhase_constraint_1, - &ASN_PER_MEMB_INTEGER_CODE_PHASE_CONSTR_7, 0, "integerCodePhase"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_integerCodePhase_constraint_1, + &ASN_PER_MEMB_INTEGER_CODE_PHASE_CONSTR_7, 0, "integerCodePhase"}, {ATF_NOFLAGS, 0, offsetof(struct GANSS_SgnElement, codePhaseRMSError), - (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_codePhaseRMSError_constraint_1, - &ASN_PER_MEMB_CODE_PHASE_RMS_ERROR_CONSTR_8, 0, "codePhaseRMSError"}, + (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_codePhaseRMSError_constraint_1, + &ASN_PER_MEMB_CODE_PHASE_RMS_ERROR_CONSTR_8, 0, "codePhaseRMSError"}, {ATF_POINTER, 2, offsetof(struct GANSS_SgnElement, doppler), - (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_doppler_constraint_1, - &ASN_PER_MEMB_DOPPLER_CONSTR_9, 0, "doppler"}, + (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_doppler_constraint_1, + &ASN_PER_MEMB_DOPPLER_CONSTR_9, 0, "doppler"}, {ATF_POINTER, 1, offsetof(struct GANSS_SgnElement, adr), - (ASN_TAG_CLASS_CONTEXT | (8 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_adr_constraint_1, &ASN_PER_MEMB_ADR_CONSTR_10, - 0, "adr"}, + (ASN_TAG_CLASS_CONTEXT | (8 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_adr_constraint_1, &ASN_PER_MEMB_ADR_CONSTR_10, + 0, "adr"}, }; static int asn_MAP_GANSS_SgnElement_oms_1[] = {3, 5, 7, 8}; static ber_tlv_tag_t asn_DEF_GANSS_SgnElement_tags_1[] = { @@ -294,12 +294,12 @@ static asn_TYPE_tag2member_t asn_MAP_GANSS_SgnElement_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0}, /* cNo at 1480 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0}, /* mpathDet at 1481 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, - 0}, /* carrierQualityInd at 1482 */ + 0}, /* carrierQualityInd at 1482 */ {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, 0}, /* codePhase at 1483 */ {(ASN_TAG_CLASS_CONTEXT | (5 << 2)), 5, 0, - 0}, /* integerCodePhase at 1484 */ + 0}, /* integerCodePhase at 1484 */ {(ASN_TAG_CLASS_CONTEXT | (6 << 2)), 6, 0, - 0}, /* codePhaseRMSError at 1485 */ + 0}, /* codePhaseRMSError at 1485 */ {(ASN_TAG_CLASS_CONTEXT | (7 << 2)), 7, 0, 0}, /* doppler at 1486 */ {(ASN_TAG_CLASS_CONTEXT | (8 << 2)), 8, 0, 0} /* adr at 1487 */ }; @@ -333,7 +333,7 @@ asn_TYPE_descriptor_t asn_DEF_GANSS_SgnElement = { asn_DEF_GANSS_SgnElement_tags_1, /* Same as above */ sizeof(asn_DEF_GANSS_SgnElement_tags_1) / sizeof(asn_DEF_GANSS_SgnElement_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSS_SgnElement_1, 9, /* Elements count */ &asn_SPC_GANSS_SgnElement_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GANSS-SgnElement.h b/src/core/libs/supl/asn-rrlp/GANSS-SgnElement.h index 401ab2b99..ad1b573b8 100644 --- a/src/core/libs/supl/asn-rrlp/GANSS-SgnElement.h +++ b/src/core/libs/supl/asn-rrlp/GANSS-SgnElement.h @@ -10,9 +10,9 @@ #include /* Including external dependencies */ +#include "MpathIndic.h" #include "SVID.h" #include -#include "MpathIndic.h" #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/GANSS-SgnTypeElement.c b/src/core/libs/supl/asn-rrlp/GANSS-SgnTypeElement.c index fac6a087f..d3cb66c9b 100644 --- a/src/core/libs/supl/asn-rrlp/GANSS-SgnTypeElement.c +++ b/src/core/libs/supl/asn-rrlp/GANSS-SgnTypeElement.c @@ -15,7 +15,7 @@ static int memb_ganssSignalID_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ static int memb_ganssSignalID_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -42,15 +42,15 @@ static asn_per_constraints_t ASN_PER_MEMB_GANSS_SIGNAL_ID_CONSTR_2 = { }; static asn_TYPE_member_t asn_MBR_GANSS_SgnTypeElement_1[] = { {ATF_NOFLAGS, 0, offsetof(struct GANSS_SgnTypeElement, ganssSignalID), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ganssSignalID_constraint_1, - &ASN_PER_MEMB_GANSS_SIGNAL_ID_CONSTR_2, 0, "ganssSignalID"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ganssSignalID_constraint_1, + &ASN_PER_MEMB_GANSS_SIGNAL_ID_CONSTR_2, 0, "ganssSignalID"}, {ATF_NOFLAGS, 0, offsetof(struct GANSS_SgnTypeElement, ganss_SgnList), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfGANSS_SgnElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganss-SgnList"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfGANSS_SgnElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganss-SgnList"}, }; static ber_tlv_tag_t asn_DEF_GANSS_SgnTypeElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -88,7 +88,7 @@ asn_TYPE_descriptor_t asn_DEF_GANSS_SgnTypeElement = { asn_DEF_GANSS_SgnTypeElement_tags_1, /* Same as above */ sizeof(asn_DEF_GANSS_SgnTypeElement_tags_1) / sizeof(asn_DEF_GANSS_SgnTypeElement_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSS_SgnTypeElement_1, 2, /* Elements count */ &asn_SPC_GANSS_SgnTypeElement_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GANSS-SgnTypeElement.h b/src/core/libs/supl/asn-rrlp/GANSS-SgnTypeElement.h index 2f74a5c22..c028a3f8e 100644 --- a/src/core/libs/supl/asn-rrlp/GANSS-SgnTypeElement.h +++ b/src/core/libs/supl/asn-rrlp/GANSS-SgnTypeElement.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include #include "SeqOfGANSS-SgnElement.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/GANSSAlmanacElement.c b/src/core/libs/supl/asn-rrlp/GANSSAlmanacElement.c index 65e7a38d8..4941e994c 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSAlmanacElement.c +++ b/src/core/libs/supl/asn-rrlp/GANSSAlmanacElement.c @@ -14,16 +14,16 @@ static asn_per_constraints_t ASN_PER_TYPE_GANSS_ALMANAC_ELEMENT_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_GANSSAlmanacElement_1[] = { {ATF_NOFLAGS, 0, - offsetof(struct GANSSAlmanacElement, choice.keplerianAlmanacSet), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Almanac_KeplerianSet, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "keplerianAlmanacSet"}, + offsetof(struct GANSSAlmanacElement, choice.keplerianAlmanacSet), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Almanac_KeplerianSet, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "keplerianAlmanacSet"}, }; static asn_TYPE_tag2member_t asn_MAP_GANSSAlmanacElement_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0} /* keplerianAlmanacSet at 1362 */ + 0} /* keplerianAlmanacSet at 1362 */ }; static asn_CHOICE_specifics_t asn_SPC_GANSSAlmanacElement_specs_1 = { sizeof(struct GANSSAlmanacElement), diff --git a/src/core/libs/supl/asn-rrlp/GANSSAlmanacModel.c b/src/core/libs/supl/asn-rrlp/GANSSAlmanacModel.c index 857969d08..7c2c989cb 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSAlmanacModel.c +++ b/src/core/libs/supl/asn-rrlp/GANSSAlmanacModel.c @@ -7,16 +7,16 @@ #include "GANSSAlmanacModel.h" static int memb_weekNumber_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,21 +30,21 @@ static int memb_weekNumber_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_toa_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -58,21 +58,21 @@ static int memb_toa_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ioda_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -86,7 +86,7 @@ static int memb_ioda_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -111,28 +111,28 @@ static asn_per_constraints_t ASN_PER_MEMB_IODA_CONSTR_5 = { }; static asn_TYPE_member_t asn_MBR_GANSSAlmanacModel_1[] = { {ATF_NOFLAGS, 0, offsetof(struct GANSSAlmanacModel, weekNumber), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_weekNumber_constraint_1, - &ASN_PER_MEMB_WEEK_NUMBER_CONSTR_2, 0, "weekNumber"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_weekNumber_constraint_1, + &ASN_PER_MEMB_WEEK_NUMBER_CONSTR_2, 0, "weekNumber"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSAlmanacModel, svIDMask), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SVIDMASK, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "svIDMask"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SVIDMASK, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "svIDMask"}, {ATF_POINTER, 2, offsetof(struct GANSSAlmanacModel, toa), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_toa_constraint_1, &ASN_PER_MEMB_TOA_CONSTR_4, - 0, "toa"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_toa_constraint_1, &ASN_PER_MEMB_TOA_CONSTR_4, + 0, "toa"}, {ATF_POINTER, 1, offsetof(struct GANSSAlmanacModel, ioda), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ioda_constraint_1, - &ASN_PER_MEMB_IODA_CONSTR_5, 0, "ioda"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ioda_constraint_1, + &ASN_PER_MEMB_IODA_CONSTR_5, 0, "ioda"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSAlmanacModel, ganssAlmanacList), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfGANSSAlmanacElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssAlmanacList"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfGANSSAlmanacElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssAlmanacList"}, }; static int asn_MAP_GANSSAlmanacModel_oms_1[] = {2, 3}; static ber_tlv_tag_t asn_DEF_GANSSAlmanacModel_tags_1[] = { @@ -142,7 +142,7 @@ static asn_TYPE_tag2member_t asn_MAP_GANSSAlmanacModel_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0}, /* svIDMask at 1349 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0}, /* toa at 1350 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, 0}, /* ioda at 1351 */ - {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, 0} /* ganssAlmanacList at 1353 */ + {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, 0} /* ganssAlmanacList at 1353 */ }; static asn_SEQUENCE_specifics_t asn_SPC_GANSSAlmanacModel_specs_1 = { sizeof(struct GANSSAlmanacModel), @@ -174,7 +174,7 @@ asn_TYPE_descriptor_t asn_DEF_GANSSAlmanacModel = { asn_DEF_GANSSAlmanacModel_tags_1, /* Same as above */ sizeof(asn_DEF_GANSSAlmanacModel_tags_1) / sizeof(asn_DEF_GANSSAlmanacModel_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSSAlmanacModel_1, 5, /* Elements count */ &asn_SPC_GANSSAlmanacModel_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GANSSAlmanacModel.h b/src/core/libs/supl/asn-rrlp/GANSSAlmanacModel.h index a07f94bb3..499a82237 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSAlmanacModel.h +++ b/src/core/libs/supl/asn-rrlp/GANSSAlmanacModel.h @@ -10,9 +10,9 @@ #include /* Including external dependencies */ -#include #include "SVIDMASK.h" #include "SeqOfGANSSAlmanacElement.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/GANSSAssistanceData.c b/src/core/libs/supl/asn-rrlp/GANSSAssistanceData.c index 76cf1fd99..658e221f8 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSAssistanceData.c +++ b/src/core/libs/supl/asn-rrlp/GANSSAssistanceData.c @@ -7,8 +7,8 @@ #include "GANSSAssistanceData.h" int GANSSAssistanceData_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const OCTET_STRING_t *st = (const OCTET_STRING_t *)sptr; size_t size; @@ -16,7 +16,7 @@ int GANSSAssistanceData_constraint(asn_TYPE_descriptor_t *td, const void *sptr, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,7 +30,7 @@ int GANSSAssistanceData_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -58,57 +58,57 @@ static void GANSSAssistanceData_1_inherit_TYPE_descriptor( } void GANSSAssistanceData_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { GANSSAssistanceData_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int GANSSAssistanceData_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, + void *app_key) { GANSSAssistanceData_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t GANSSAssistanceData_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, + const void *bufptr, size_t size, + int tag_mode) { GANSSAssistanceData_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t GANSSAssistanceData_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { GANSSAssistanceData_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t GANSSAssistanceData_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { GANSSAssistanceData_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t GANSSAssistanceData_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { GANSSAssistanceData_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); @@ -121,7 +121,7 @@ asn_dec_rval_t GANSSAssistanceData_decode_uper( { GANSSAssistanceData_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t GANSSAssistanceData_encode_uper( diff --git a/src/core/libs/supl/asn-rrlp/GANSSClockModel.c b/src/core/libs/supl/asn-rrlp/GANSSClockModel.c index f87425813..2f90a9c5e 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSClockModel.c +++ b/src/core/libs/supl/asn-rrlp/GANSSClockModel.c @@ -14,16 +14,16 @@ static asn_per_constraints_t ASN_PER_TYPE_GANSS_CLOCK_MODEL_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_GANSSClockModel_1[] = { {ATF_NOFLAGS, 0, - offsetof(struct GANSSClockModel, choice.standardClockModelList), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfStandardClockModelElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "standardClockModelList"}, + offsetof(struct GANSSClockModel, choice.standardClockModelList), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfStandardClockModelElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "standardClockModelList"}, }; static asn_TYPE_tag2member_t asn_MAP_GANSSClockModel_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0} /* standardClockModelList at 1274 */ + 0} /* standardClockModelList at 1274 */ }; static asn_CHOICE_specifics_t asn_SPC_GANSSClockModel_specs_1 = { sizeof(struct GANSSClockModel), diff --git a/src/core/libs/supl/asn-rrlp/GANSSCommonAssistData.c b/src/core/libs/supl/asn-rrlp/GANSSCommonAssistData.c index ff6e0a2d2..6b82d0242 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSCommonAssistData.c +++ b/src/core/libs/supl/asn-rrlp/GANSSCommonAssistData.c @@ -8,35 +8,35 @@ static asn_TYPE_member_t asn_MBR_GANSSCommonAssistData_1[] = { {ATF_POINTER, 3, offsetof(struct GANSSCommonAssistData, ganssReferenceTime), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSReferenceTime, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssReferenceTime"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSReferenceTime, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssReferenceTime"}, {ATF_POINTER, 2, offsetof(struct GANSSCommonAssistData, ganssRefLocation), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSRefLocation, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssRefLocation"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSRefLocation, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssRefLocation"}, {ATF_POINTER, 1, - offsetof(struct GANSSCommonAssistData, ganssIonosphericModel), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSIonosphericModel, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssIonosphericModel"}, + offsetof(struct GANSSCommonAssistData, ganssIonosphericModel), + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSIonosphericModel, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssIonosphericModel"}, }; static int asn_MAP_GANSSCommonAssistData_oms_1[] = {0, 1, 2}; static ber_tlv_tag_t asn_DEF_GANSSCommonAssistData_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_GANSSCommonAssistData_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0}, /* ganssReferenceTime at 1071 */ + 0}, /* ganssReferenceTime at 1071 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0}, /* ganssRefLocation at 1072 */ + 0}, /* ganssRefLocation at 1072 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, - 0} /* ganssIonosphericModel at 1073 */ + 0} /* ganssIonosphericModel at 1073 */ }; static asn_SEQUENCE_specifics_t asn_SPC_GANSSCommonAssistData_specs_1 = { sizeof(struct GANSSCommonAssistData), @@ -68,7 +68,7 @@ asn_TYPE_descriptor_t asn_DEF_GANSSCommonAssistData = { asn_DEF_GANSSCommonAssistData_tags_1, /* Same as above */ sizeof(asn_DEF_GANSSCommonAssistData_tags_1) / sizeof(asn_DEF_GANSSCommonAssistData_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSSCommonAssistData_1, 3, /* Elements count */ &asn_SPC_GANSSCommonAssistData_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GANSSCommonAssistData.h b/src/core/libs/supl/asn-rrlp/GANSSCommonAssistData.h index 0ea6e438c..85d8fe64e 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSCommonAssistData.h +++ b/src/core/libs/supl/asn-rrlp/GANSSCommonAssistData.h @@ -45,9 +45,9 @@ extern "C" #endif /* Referred external types */ -#include "GANSSReferenceTime.h" -#include "GANSSRefLocation.h" #include "GANSSIonosphericModel.h" +#include "GANSSRefLocation.h" +#include "GANSSReferenceTime.h" #endif /* _GANSSCommonAssistData_H_ */ #include diff --git a/src/core/libs/supl/asn-rrlp/GANSSDataBit.c b/src/core/libs/supl/asn-rrlp/GANSSDataBit.c index c074d685e..4fc0e9ad6 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSDataBit.c +++ b/src/core/libs/supl/asn-rrlp/GANSSDataBit.c @@ -7,15 +7,15 @@ #include "GANSSDataBit.h" int GANSSDataBit_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ int GANSSDataBit_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -56,74 +56,74 @@ static void GANSSDataBit_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void GANSSDataBit_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { GANSSDataBit_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int GANSSDataBit_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { GANSSDataBit_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t GANSSDataBit_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { GANSSDataBit_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t GANSSDataBit_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { GANSSDataBit_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t GANSSDataBit_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, const char *opt_mname, + const void *bufptr, size_t size) { GANSSDataBit_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t GANSSDataBit_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { GANSSDataBit_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t GANSSDataBit_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { GANSSDataBit_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t GANSSDataBit_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { GANSSDataBit_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/GANSSDataBitAssist.c b/src/core/libs/supl/asn-rrlp/GANSSDataBitAssist.c index d09a05716..d669c5708 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSDataBitAssist.c +++ b/src/core/libs/supl/asn-rrlp/GANSSDataBitAssist.c @@ -7,16 +7,16 @@ #include "GANSSDataBitAssist.h" static int memb_ganssTOD_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,7 +30,7 @@ static int memb_ganssTOD_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -44,7 +44,7 @@ static int memb_ganssDataTypeID_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -58,7 +58,7 @@ static int memb_ganssDataTypeID_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -77,24 +77,24 @@ static asn_per_constraints_t ASN_PER_MEMB_GANSS_DATA_TYPE_ID_CONSTR_4 = { }; static asn_TYPE_member_t asn_MBR_GANSSDataBitAssist_1[] = { {ATF_NOFLAGS, 0, offsetof(struct GANSSDataBitAssist, ganssTOD), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ganssTOD_constraint_1, - &ASN_PER_MEMB_GANSS_TOD_CONSTR_2, 0, "ganssTOD"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ganssTOD_constraint_1, + &ASN_PER_MEMB_GANSS_TOD_CONSTR_2, 0, "ganssTOD"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSDataBitAssist, svID), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SVID, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "svID"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SVID, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "svID"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSDataBitAssist, ganssDataTypeID), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ganssDataTypeID_constraint_1, - &ASN_PER_MEMB_GANSS_DATA_TYPE_ID_CONSTR_4, 0, "ganssDataTypeID"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ganssDataTypeID_constraint_1, + &ASN_PER_MEMB_GANSS_DATA_TYPE_ID_CONSTR_4, 0, "ganssDataTypeID"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSDataBitAssist, ganssDataBits), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOf_GANSSDataBits, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssDataBits"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOf_GANSSDataBits, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssDataBits"}, }; static ber_tlv_tag_t asn_DEF_GANSSDataBitAssist_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -134,7 +134,7 @@ asn_TYPE_descriptor_t asn_DEF_GANSSDataBitAssist = { asn_DEF_GANSSDataBitAssist_tags_1, /* Same as above */ sizeof(asn_DEF_GANSSDataBitAssist_tags_1) / sizeof(asn_DEF_GANSSDataBitAssist_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSSDataBitAssist_1, 4, /* Elements count */ &asn_SPC_GANSSDataBitAssist_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GANSSDataBitAssist.h b/src/core/libs/supl/asn-rrlp/GANSSDataBitAssist.h index a3a8b9ff4..e553d0e3d 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSDataBitAssist.h +++ b/src/core/libs/supl/asn-rrlp/GANSSDataBitAssist.h @@ -10,9 +10,9 @@ #include /* Including external dependencies */ -#include #include "SVID.h" #include "SeqOf-GANSSDataBits.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/GANSSDiffCorrections.c b/src/core/libs/supl/asn-rrlp/GANSSDiffCorrections.c index ee79f0470..e7fbb502f 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSDiffCorrections.c +++ b/src/core/libs/supl/asn-rrlp/GANSSDiffCorrections.c @@ -15,7 +15,7 @@ static int memb_dganssRefTime_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ static int memb_dganssRefTime_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -42,15 +42,15 @@ static asn_per_constraints_t ASN_PER_MEMB_DGANSS_REF_TIME_CONSTR_2 = { }; static asn_TYPE_member_t asn_MBR_GANSSDiffCorrections_1[] = { {ATF_NOFLAGS, 0, offsetof(struct GANSSDiffCorrections, dganssRefTime), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_dganssRefTime_constraint_1, - &ASN_PER_MEMB_DGANSS_REF_TIME_CONSTR_2, 0, "dganssRefTime"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_dganssRefTime_constraint_1, + &ASN_PER_MEMB_DGANSS_REF_TIME_CONSTR_2, 0, "dganssRefTime"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSDiffCorrections, sgnTypeList), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfSgnTypeElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "sgnTypeList"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfSgnTypeElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "sgnTypeList"}, }; static ber_tlv_tag_t asn_DEF_GANSSDiffCorrections_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -88,7 +88,7 @@ asn_TYPE_descriptor_t asn_DEF_GANSSDiffCorrections = { asn_DEF_GANSSDiffCorrections_tags_1, /* Same as above */ sizeof(asn_DEF_GANSSDiffCorrections_tags_1) / sizeof(asn_DEF_GANSSDiffCorrections_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSSDiffCorrections_1, 2, /* Elements count */ &asn_SPC_GANSSDiffCorrections_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GANSSDiffCorrections.h b/src/core/libs/supl/asn-rrlp/GANSSDiffCorrections.h index a50a1d558..bbd129b96 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSDiffCorrections.h +++ b/src/core/libs/supl/asn-rrlp/GANSSDiffCorrections.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include #include "SeqOfSgnTypeElement.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/GANSSGenericAssistDataElement.c b/src/core/libs/supl/asn-rrlp/GANSSGenericAssistDataElement.c index 6c6fa96e9..16f4243fd 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSGenericAssistDataElement.c +++ b/src/core/libs/supl/asn-rrlp/GANSSGenericAssistDataElement.c @@ -7,16 +7,16 @@ #include "GANSSGenericAssistDataElement.h" static int memb_ganssID_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,7 +30,7 @@ static int memb_ganssID_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -43,96 +43,96 @@ static asn_per_constraints_t ASN_PER_MEMB_GANSS_ID_CONSTR_2 = { }; static asn_TYPE_member_t asn_MBR_GANSSGenericAssistDataElement_1[] = { {ATF_POINTER, 9, offsetof(struct GANSSGenericAssistDataElement, ganssID), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ganssID_constraint_1, - &ASN_PER_MEMB_GANSS_ID_CONSTR_2, 0, "ganssID"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ganssID_constraint_1, + &ASN_PER_MEMB_GANSS_ID_CONSTR_2, 0, "ganssID"}, {ATF_POINTER, 8, - offsetof(struct GANSSGenericAssistDataElement, ganssTimeModel), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfGANSSTimeModel, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssTimeModel"}, + offsetof(struct GANSSGenericAssistDataElement, ganssTimeModel), + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfGANSSTimeModel, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssTimeModel"}, {ATF_POINTER, 7, - offsetof(struct GANSSGenericAssistDataElement, ganssDiffCorrections), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSDiffCorrections, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssDiffCorrections"}, + offsetof(struct GANSSGenericAssistDataElement, ganssDiffCorrections), + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSDiffCorrections, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssDiffCorrections"}, {ATF_POINTER, 6, - offsetof(struct GANSSGenericAssistDataElement, ganssNavigationModel), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSNavModel, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssNavigationModel"}, + offsetof(struct GANSSGenericAssistDataElement, ganssNavigationModel), + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSNavModel, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssNavigationModel"}, {ATF_POINTER, 5, - offsetof(struct GANSSGenericAssistDataElement, ganssRealTimeIntegrity), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSRealTimeIntegrity, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssRealTimeIntegrity"}, + offsetof(struct GANSSGenericAssistDataElement, ganssRealTimeIntegrity), + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSRealTimeIntegrity, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssRealTimeIntegrity"}, {ATF_POINTER, 4, - offsetof(struct GANSSGenericAssistDataElement, ganssDataBitAssist), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSDataBitAssist, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssDataBitAssist"}, + offsetof(struct GANSSGenericAssistDataElement, ganssDataBitAssist), + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSDataBitAssist, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssDataBitAssist"}, {ATF_POINTER, 3, - offsetof(struct GANSSGenericAssistDataElement, ganssRefMeasurementAssist), - (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSRefMeasurementAssist, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssRefMeasurementAssist"}, + offsetof(struct GANSSGenericAssistDataElement, ganssRefMeasurementAssist), + (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSRefMeasurementAssist, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssRefMeasurementAssist"}, {ATF_POINTER, 2, - offsetof(struct GANSSGenericAssistDataElement, ganssAlmanacModel), - (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSAlmanacModel, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssAlmanacModel"}, + offsetof(struct GANSSGenericAssistDataElement, ganssAlmanacModel), + (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSAlmanacModel, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssAlmanacModel"}, {ATF_POINTER, 1, - offsetof(struct GANSSGenericAssistDataElement, ganssUTCModel), - (ASN_TAG_CLASS_CONTEXT | (8 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSUTCModel, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssUTCModel"}, + offsetof(struct GANSSGenericAssistDataElement, ganssUTCModel), + (ASN_TAG_CLASS_CONTEXT | (8 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSUTCModel, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssUTCModel"}, }; static int asn_MAP_GANSSGenericAssistDataElement_oms_1[] = {0, 1, 2, 3, 4, - 5, 6, 7, 8}; + 5, 6, 7, 8}; static ber_tlv_tag_t asn_DEF_GANSSGenericAssistDataElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_GANSSGenericAssistDataElement_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* ganssID at 1082 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0}, /* ganssTimeModel at 1083 */ + 0}, /* ganssTimeModel at 1083 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, - 0}, /* ganssDiffCorrections at 1084 */ + 0}, /* ganssDiffCorrections at 1084 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, - 0}, /* ganssNavigationModel at 1085 */ + 0}, /* ganssNavigationModel at 1085 */ {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, - 0}, /* ganssRealTimeIntegrity at 1086 */ + 0}, /* ganssRealTimeIntegrity at 1086 */ {(ASN_TAG_CLASS_CONTEXT | (5 << 2)), 5, 0, - 0}, /* ganssDataBitAssist at 1087 */ + 0}, /* ganssDataBitAssist at 1087 */ {(ASN_TAG_CLASS_CONTEXT | (6 << 2)), 6, 0, - 0}, /* ganssRefMeasurementAssist at 1088 */ + 0}, /* ganssRefMeasurementAssist at 1088 */ {(ASN_TAG_CLASS_CONTEXT | (7 << 2)), 7, 0, - 0}, /* ganssAlmanacModel at 1089 */ + 0}, /* ganssAlmanacModel at 1089 */ {(ASN_TAG_CLASS_CONTEXT | (8 << 2)), 8, 0, - 0} /* ganssUTCModel at 1090 */ + 0} /* ganssUTCModel at 1090 */ }; static asn_SEQUENCE_specifics_t asn_SPC_GANSSGenericAssistDataElement_specs_1 = { sizeof(struct GANSSGenericAssistDataElement), offsetof(struct GANSSGenericAssistDataElement, _asn_ctx), asn_MAP_GANSSGenericAssistDataElement_tag2el_1, - 9, /* Count of tags in the map */ + 9, /* Count of tags in the map */ asn_MAP_GANSSGenericAssistDataElement_oms_1, /* Optional members */ 9, 0, /* Root/Additions */ @@ -155,10 +155,10 @@ asn_TYPE_descriptor_t asn_DEF_GANSSGenericAssistDataElement = { asn_DEF_GANSSGenericAssistDataElement_tags_1, sizeof(asn_DEF_GANSSGenericAssistDataElement_tags_1) / sizeof(asn_DEF_GANSSGenericAssistDataElement_tags_1[0]), /* 1 */ - asn_DEF_GANSSGenericAssistDataElement_tags_1, /* Same as above */ + asn_DEF_GANSSGenericAssistDataElement_tags_1, /* Same as above */ sizeof(asn_DEF_GANSSGenericAssistDataElement_tags_1) / sizeof(asn_DEF_GANSSGenericAssistDataElement_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSSGenericAssistDataElement_1, 9, /* Elements count */ &asn_SPC_GANSSGenericAssistDataElement_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GANSSGenericAssistDataElement.h b/src/core/libs/supl/asn-rrlp/GANSSGenericAssistDataElement.h index ef9310716..14760ea0b 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSGenericAssistDataElement.h +++ b/src/core/libs/supl/asn-rrlp/GANSSGenericAssistDataElement.h @@ -58,14 +58,14 @@ extern "C" #endif /* Referred external types */ -#include "SeqOfGANSSTimeModel.h" +#include "GANSSAlmanacModel.h" +#include "GANSSDataBitAssist.h" #include "GANSSDiffCorrections.h" #include "GANSSNavModel.h" #include "GANSSRealTimeIntegrity.h" -#include "GANSSDataBitAssist.h" #include "GANSSRefMeasurementAssist.h" -#include "GANSSAlmanacModel.h" #include "GANSSUTCModel.h" +#include "SeqOfGANSSTimeModel.h" #endif /* _GANSSGenericAssistDataElement_H_ */ #include diff --git a/src/core/libs/supl/asn-rrlp/GANSSIonoStormFlags.c b/src/core/libs/supl/asn-rrlp/GANSSIonoStormFlags.c index 5fc30c9e4..070b4fa6d 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSIonoStormFlags.c +++ b/src/core/libs/supl/asn-rrlp/GANSSIonoStormFlags.c @@ -15,7 +15,7 @@ static int memb_ionoStormFlag1_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ static int memb_ionoStormFlag1_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -43,7 +43,7 @@ static int memb_ionoStormFlag2_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -57,7 +57,7 @@ static int memb_ionoStormFlag2_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -71,7 +71,7 @@ static int memb_ionoStormFlag3_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -85,7 +85,7 @@ static int memb_ionoStormFlag3_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -99,7 +99,7 @@ static int memb_ionoStormFlag4_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -113,7 +113,7 @@ static int memb_ionoStormFlag4_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -127,7 +127,7 @@ static int memb_ionoStormFlag5_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -141,7 +141,7 @@ static int memb_ionoStormFlag5_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -178,25 +178,25 @@ static asn_per_constraints_t ASN_PER_MEMB_IONO_STORM_FLAG5_CONSTR_6 = { }; static asn_TYPE_member_t asn_MBR_GANSSIonoStormFlags_1[] = { {ATF_NOFLAGS, 0, offsetof(struct GANSSIonoStormFlags, ionoStormFlag1), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ionoStormFlag1_constraint_1, - &ASN_PER_MEMB_IONO_STORM_FLAG1_CONSTR_2, 0, "ionoStormFlag1"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ionoStormFlag1_constraint_1, + &ASN_PER_MEMB_IONO_STORM_FLAG1_CONSTR_2, 0, "ionoStormFlag1"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSIonoStormFlags, ionoStormFlag2), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ionoStormFlag2_constraint_1, - &ASN_PER_MEMB_IONO_STORM_FLAG2_CONSTR_3, 0, "ionoStormFlag2"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ionoStormFlag2_constraint_1, + &ASN_PER_MEMB_IONO_STORM_FLAG2_CONSTR_3, 0, "ionoStormFlag2"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSIonoStormFlags, ionoStormFlag3), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ionoStormFlag3_constraint_1, - &ASN_PER_MEMB_IONO_STORM_FLAG3_CONSTR_4, 0, "ionoStormFlag3"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ionoStormFlag3_constraint_1, + &ASN_PER_MEMB_IONO_STORM_FLAG3_CONSTR_4, 0, "ionoStormFlag3"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSIonoStormFlags, ionoStormFlag4), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ionoStormFlag4_constraint_1, - &ASN_PER_MEMB_IONO_STORM_FLAG4_CONSTR_5, 0, "ionoStormFlag4"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ionoStormFlag4_constraint_1, + &ASN_PER_MEMB_IONO_STORM_FLAG4_CONSTR_5, 0, "ionoStormFlag4"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSIonoStormFlags, ionoStormFlag5), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ionoStormFlag5_constraint_1, - &ASN_PER_MEMB_IONO_STORM_FLAG5_CONSTR_6, 0, "ionoStormFlag5"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ionoStormFlag5_constraint_1, + &ASN_PER_MEMB_IONO_STORM_FLAG5_CONSTR_6, 0, "ionoStormFlag5"}, }; static ber_tlv_tag_t asn_DEF_GANSSIonoStormFlags_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -237,7 +237,7 @@ asn_TYPE_descriptor_t asn_DEF_GANSSIonoStormFlags = { asn_DEF_GANSSIonoStormFlags_tags_1, /* Same as above */ sizeof(asn_DEF_GANSSIonoStormFlags_tags_1) / sizeof(asn_DEF_GANSSIonoStormFlags_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSSIonoStormFlags_1, 5, /* Elements count */ &asn_SPC_GANSSIonoStormFlags_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GANSSIonosphereModel.c b/src/core/libs/supl/asn-rrlp/GANSSIonosphereModel.c index 5b0e9d6a9..16744e7d2 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSIonosphereModel.c +++ b/src/core/libs/supl/asn-rrlp/GANSSIonosphereModel.c @@ -7,15 +7,15 @@ #include "GANSSIonosphereModel.h" static int memb_ai0_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,21 +29,21 @@ static int memb_ai0_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ai1_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -57,21 +57,21 @@ static int memb_ai1_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ai2_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -85,7 +85,7 @@ static int memb_ai2_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -110,17 +110,17 @@ static asn_per_constraints_t ASN_PER_MEMB_AI2_CONSTR_4 = { }; static asn_TYPE_member_t asn_MBR_GANSSIonosphereModel_1[] = { {ATF_NOFLAGS, 0, offsetof(struct GANSSIonosphereModel, ai0), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ai0_constraint_1, &ASN_PER_MEMB_AI0_CONSTR_2, - 0, "ai0"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ai0_constraint_1, &ASN_PER_MEMB_AI0_CONSTR_2, + 0, "ai0"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSIonosphereModel, ai1), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ai1_constraint_1, &ASN_PER_MEMB_AI1_CONSTR_3, - 0, "ai1"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ai1_constraint_1, &ASN_PER_MEMB_AI1_CONSTR_3, + 0, "ai1"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSIonosphereModel, ai2), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ai2_constraint_1, &ASN_PER_MEMB_AI2_CONSTR_4, - 0, "ai2"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ai2_constraint_1, &ASN_PER_MEMB_AI2_CONSTR_4, + 0, "ai2"}, }; static ber_tlv_tag_t asn_DEF_GANSSIonosphereModel_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -159,7 +159,7 @@ asn_TYPE_descriptor_t asn_DEF_GANSSIonosphereModel = { asn_DEF_GANSSIonosphereModel_tags_1, /* Same as above */ sizeof(asn_DEF_GANSSIonosphereModel_tags_1) / sizeof(asn_DEF_GANSSIonosphereModel_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSSIonosphereModel_1, 3, /* Elements count */ &asn_SPC_GANSSIonosphereModel_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GANSSIonosphericModel.c b/src/core/libs/supl/asn-rrlp/GANSSIonosphericModel.c index 7700242c7..26a3bac3f 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSIonosphericModel.c +++ b/src/core/libs/supl/asn-rrlp/GANSSIonosphericModel.c @@ -8,18 +8,18 @@ static asn_TYPE_member_t asn_MBR_GANSSIonosphericModel_1[] = { {ATF_NOFLAGS, 0, offsetof(struct GANSSIonosphericModel, ganssIonoModel), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSIonosphereModel, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssIonoModel"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSIonosphereModel, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssIonoModel"}, {ATF_POINTER, 1, - offsetof(struct GANSSIonosphericModel, ganssIonoStormFlags), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSIonoStormFlags, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssIonoStormFlags"}, + offsetof(struct GANSSIonosphericModel, ganssIonoStormFlags), + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSIonoStormFlags, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssIonoStormFlags"}, }; static int asn_MAP_GANSSIonosphericModel_oms_1[] = {1}; static ber_tlv_tag_t asn_DEF_GANSSIonosphericModel_tags_1[] = { @@ -27,7 +27,7 @@ static ber_tlv_tag_t asn_DEF_GANSSIonosphericModel_tags_1[] = { static asn_TYPE_tag2member_t asn_MAP_GANSSIonosphericModel_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* ganssIonoModel at 1138 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0} /* ganssIonoStormFlags at 1139 */ + 0} /* ganssIonoStormFlags at 1139 */ }; static asn_SEQUENCE_specifics_t asn_SPC_GANSSIonosphericModel_specs_1 = { sizeof(struct GANSSIonosphericModel), @@ -59,7 +59,7 @@ asn_TYPE_descriptor_t asn_DEF_GANSSIonosphericModel = { asn_DEF_GANSSIonosphericModel_tags_1, /* Same as above */ sizeof(asn_DEF_GANSSIonosphericModel_tags_1) / sizeof(asn_DEF_GANSSIonosphericModel_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSSIonosphericModel_1, 2, /* Elements count */ &asn_SPC_GANSSIonosphericModel_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GANSSLocationInfo.c b/src/core/libs/supl/asn-rrlp/GANSSLocationInfo.c index 240bd3cdd..ff59391f0 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSLocationInfo.c +++ b/src/core/libs/supl/asn-rrlp/GANSSLocationInfo.c @@ -7,16 +7,16 @@ #include "GANSSLocationInfo.h" static int memb_ganssTODFrac_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,22 +30,22 @@ static int memb_ganssTODFrac_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ganssTimeID_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -59,7 +59,7 @@ static int memb_ganssTimeID_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -73,7 +73,7 @@ static int memb_stationaryIndication_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -87,7 +87,7 @@ static int memb_stationaryIndication_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -112,51 +112,51 @@ static asn_per_constraints_t ASN_PER_MEMB_STATIONARY_INDICATION_CONSTR_9 = { }; static asn_TYPE_member_t asn_MBR_GANSSLocationInfo_1[] = { {ATF_POINTER, 5, offsetof(struct GANSSLocationInfo, referenceFrame), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_ReferenceFrame, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "referenceFrame"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_ReferenceFrame, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "referenceFrame"}, {ATF_POINTER, 4, offsetof(struct GANSSLocationInfo, ganssTODm), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSTODm, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssTODm"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSTODm, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssTODm"}, {ATF_POINTER, 3, offsetof(struct GANSSLocationInfo, ganssTODFrac), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ganssTODFrac_constraint_1, - &ASN_PER_MEMB_GANSS_TOD_FRAC_CONSTR_4, 0, "ganssTODFrac"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ganssTODFrac_constraint_1, + &ASN_PER_MEMB_GANSS_TOD_FRAC_CONSTR_4, 0, "ganssTODFrac"}, {ATF_POINTER, 2, offsetof(struct GANSSLocationInfo, ganssTODUncertainty), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSTODUncertainty, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssTODUncertainty"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSTODUncertainty, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssTODUncertainty"}, {ATF_POINTER, 1, offsetof(struct GANSSLocationInfo, ganssTimeID), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ganssTimeID_constraint_1, - &ASN_PER_MEMB_GANSS_TIME_ID_CONSTR_6, 0, "ganssTimeID"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ganssTimeID_constraint_1, + &ASN_PER_MEMB_GANSS_TIME_ID_CONSTR_6, 0, "ganssTimeID"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSLocationInfo, fixType), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_FixType, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "fixType"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_FixType, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "fixType"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSLocationInfo, posData), - (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_PositionData, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "posData"}, + (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_PositionData, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "posData"}, {ATF_POINTER, 1, offsetof(struct GANSSLocationInfo, stationaryIndication), - (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_stationaryIndication_constraint_1, - &ASN_PER_MEMB_STATIONARY_INDICATION_CONSTR_9, 0, "stationaryIndication"}, + (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_stationaryIndication_constraint_1, + &ASN_PER_MEMB_STATIONARY_INDICATION_CONSTR_9, 0, "stationaryIndication"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSLocationInfo, posEstimate), - (ASN_TAG_CLASS_CONTEXT | (8 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Ext_GeographicalInformation, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "posEstimate"}, + (ASN_TAG_CLASS_CONTEXT | (8 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Ext_GeographicalInformation, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "posEstimate"}, }; static int asn_MAP_GANSSLocationInfo_oms_1[] = {0, 1, 2, 3, 4, 7}; static ber_tlv_tag_t asn_DEF_GANSSLocationInfo_tags_1[] = { @@ -166,12 +166,12 @@ static asn_TYPE_tag2member_t asn_MAP_GANSSLocationInfo_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0}, /* ganssTODm at 1412 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0}, /* ganssTODFrac at 1413 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, - 0}, /* ganssTODUncertainty at 1414 */ + 0}, /* ganssTODUncertainty at 1414 */ {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, 0}, /* ganssTimeID at 1415 */ {(ASN_TAG_CLASS_CONTEXT | (5 << 2)), 5, 0, 0}, /* fixType at 1416 */ {(ASN_TAG_CLASS_CONTEXT | (6 << 2)), 6, 0, 0}, /* posData at 1417 */ {(ASN_TAG_CLASS_CONTEXT | (7 << 2)), 7, 0, - 0}, /* stationaryIndication at 1418 */ + 0}, /* stationaryIndication at 1418 */ {(ASN_TAG_CLASS_CONTEXT | (8 << 2)), 8, 0, 0} /* posEstimate at 1424 */ }; static asn_SEQUENCE_specifics_t asn_SPC_GANSSLocationInfo_specs_1 = { @@ -204,7 +204,7 @@ asn_TYPE_descriptor_t asn_DEF_GANSSLocationInfo = { asn_DEF_GANSSLocationInfo_tags_1, /* Same as above */ sizeof(asn_DEF_GANSSLocationInfo_tags_1) / sizeof(asn_DEF_GANSSLocationInfo_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSSLocationInfo_1, 9, /* Elements count */ &asn_SPC_GANSSLocationInfo_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GANSSLocationInfo.h b/src/core/libs/supl/asn-rrlp/GANSSLocationInfo.h index 4c9c2eb32..2f9f423d4 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSLocationInfo.h +++ b/src/core/libs/supl/asn-rrlp/GANSSLocationInfo.h @@ -10,12 +10,12 @@ #include /* Including external dependencies */ -#include "GANSSTODm.h" -#include -#include "GANSSTODUncertainty.h" -#include "FixType.h" -#include "PositionData.h" #include "Ext-GeographicalInformation.h" +#include "FixType.h" +#include "GANSSTODUncertainty.h" +#include "GANSSTODm.h" +#include "PositionData.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/GANSSMeasureInfo.c b/src/core/libs/supl/asn-rrlp/GANSSMeasureInfo.c index 9f4f2871b..057ed48fe 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSMeasureInfo.c +++ b/src/core/libs/supl/asn-rrlp/GANSSMeasureInfo.c @@ -8,11 +8,11 @@ static asn_TYPE_member_t asn_MBR_GANSSMeasureInfo_1[] = { {ATF_NOFLAGS, 0, offsetof(struct GANSSMeasureInfo, ganssMsrSetList), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfGANSS_MsrSetElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssMsrSetList"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfGANSS_MsrSetElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssMsrSetList"}, }; static ber_tlv_tag_t asn_DEF_GANSSMeasureInfo_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -49,7 +49,7 @@ asn_TYPE_descriptor_t asn_DEF_GANSSMeasureInfo = { asn_DEF_GANSSMeasureInfo_tags_1, /* Same as above */ sizeof(asn_DEF_GANSSMeasureInfo_tags_1) / sizeof(asn_DEF_GANSSMeasureInfo_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSSMeasureInfo_1, 1, /* Elements count */ &asn_SPC_GANSSMeasureInfo_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GANSSNavModel.c b/src/core/libs/supl/asn-rrlp/GANSSNavModel.c index 6aee05e96..3c74c4110 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSNavModel.c +++ b/src/core/libs/supl/asn-rrlp/GANSSNavModel.c @@ -15,7 +15,7 @@ static int memb_nonBroadcastIndFlag_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,21 +29,21 @@ static int memb_nonBroadcastIndFlag_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_toeMSB_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -57,21 +57,21 @@ static int memb_toeMSB_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_eMSB_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -85,22 +85,22 @@ static int memb_eMSB_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_sqrtAMBS_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -114,7 +114,7 @@ static int memb_sqrtAMBS_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -145,39 +145,39 @@ static asn_per_constraints_t ASN_PER_MEMB_SQRT_AMBS_CONSTR_5 = { }; static asn_TYPE_member_t asn_MBR_GANSSNavModel_1[] = { {ATF_NOFLAGS, 0, offsetof(struct GANSSNavModel, nonBroadcastIndFlag), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_nonBroadcastIndFlag_constraint_1, - &ASN_PER_MEMB_NON_BROADCAST_IND_FLAG_CONSTR_2, 0, "nonBroadcastIndFlag"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_nonBroadcastIndFlag_constraint_1, + &ASN_PER_MEMB_NON_BROADCAST_IND_FLAG_CONSTR_2, 0, "nonBroadcastIndFlag"}, {ATF_POINTER, 3, offsetof(struct GANSSNavModel, toeMSB), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_toeMSB_constraint_1, - &ASN_PER_MEMB_TOE_MSB_CONSTR_3, 0, "toeMSB"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_toeMSB_constraint_1, + &ASN_PER_MEMB_TOE_MSB_CONSTR_3, 0, "toeMSB"}, {ATF_POINTER, 2, offsetof(struct GANSSNavModel, eMSB), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_eMSB_constraint_1, - &ASN_PER_MEMB_E_MSB_CONSTR_4, 0, "eMSB"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_eMSB_constraint_1, + &ASN_PER_MEMB_E_MSB_CONSTR_4, 0, "eMSB"}, {ATF_POINTER, 1, offsetof(struct GANSSNavModel, sqrtAMBS), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_sqrtAMBS_constraint_1, - &ASN_PER_MEMB_SQRT_AMBS_CONSTR_5, 0, "sqrtAMBS"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_sqrtAMBS_constraint_1, + &ASN_PER_MEMB_SQRT_AMBS_CONSTR_5, 0, "sqrtAMBS"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSNavModel, ganssSatelliteList), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfGANSSSatelliteElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssSatelliteList"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfGANSSSatelliteElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssSatelliteList"}, }; static int asn_MAP_GANSSNavModel_oms_1[] = {1, 2, 3}; static ber_tlv_tag_t asn_DEF_GANSSNavModel_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_GANSSNavModel_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0}, /* nonBroadcastIndFlag at 1228 */ + 0}, /* nonBroadcastIndFlag at 1228 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0}, /* toeMSB at 1229 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0}, /* eMSB at 1230 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, 0}, /* sqrtAMBS at 1231 */ {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, - 0} /* ganssSatelliteList at 1233 */ + 0} /* ganssSatelliteList at 1233 */ }; static asn_SEQUENCE_specifics_t asn_SPC_GANSSNavModel_specs_1 = { sizeof(struct GANSSNavModel), @@ -209,7 +209,7 @@ asn_TYPE_descriptor_t asn_DEF_GANSSNavModel = { asn_DEF_GANSSNavModel_tags_1, /* Same as above */ sizeof(asn_DEF_GANSSNavModel_tags_1) / sizeof(asn_DEF_GANSSNavModel_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSSNavModel_1, 5, /* Elements count */ &asn_SPC_GANSSNavModel_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GANSSNavModel.h b/src/core/libs/supl/asn-rrlp/GANSSNavModel.h index d9ac45bb4..7441604d6 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSNavModel.h +++ b/src/core/libs/supl/asn-rrlp/GANSSNavModel.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include #include "SeqOfGANSSSatelliteElement.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/GANSSOrbitModel.c b/src/core/libs/supl/asn-rrlp/GANSSOrbitModel.c index 47b8e034e..256825a1f 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSOrbitModel.c +++ b/src/core/libs/supl/asn-rrlp/GANSSOrbitModel.c @@ -14,11 +14,11 @@ static asn_per_constraints_t ASN_PER_TYPE_GANSS_ORBIT_MODEL_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_GANSSOrbitModel_1[] = { {ATF_NOFLAGS, 0, offsetof(struct GANSSOrbitModel, choice.keplerianSet), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NavModel_KeplerianSet, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "keplerianSet"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NavModel_KeplerianSet, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "keplerianSet"}, }; static asn_TYPE_tag2member_t asn_MAP_GANSSOrbitModel_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0} /* keplerianSet at 1248 */ diff --git a/src/core/libs/supl/asn-rrlp/GANSSPositioningMethod.c b/src/core/libs/supl/asn-rrlp/GANSSPositioningMethod.c index 026dff1a8..61a957486 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSPositioningMethod.c +++ b/src/core/libs/supl/asn-rrlp/GANSSPositioningMethod.c @@ -7,9 +7,9 @@ #include "GANSSPositioningMethod.h" int GANSSPositioningMethod_constraint(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const BIT_STRING_t *st = (const BIT_STRING_t *)sptr; size_t size; @@ -17,7 +17,7 @@ int GANSSPositioningMethod_constraint(asn_TYPE_descriptor_t *td, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -39,7 +39,7 @@ int GANSSPositioningMethod_constraint(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -67,36 +67,36 @@ static void GANSSPositioningMethod_1_inherit_TYPE_descriptor( } void GANSSPositioningMethod_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { GANSSPositioningMethod_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int GANSSPositioningMethod_print(asn_TYPE_descriptor_t *td, - const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + const void *struct_ptr, int ilevel, + asn_app_consume_bytes_f *cb, void *app_key) { GANSSPositioningMethod_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t GANSSPositioningMethod_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, + const void *bufptr, + size_t size, int tag_mode) { GANSSPositioningMethod_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t GANSSPositioningMethod_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { GANSSPositioningMethod_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); @@ -108,14 +108,14 @@ asn_dec_rval_t GANSSPositioningMethod_decode_xer( { GANSSPositioningMethod_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t GANSSPositioningMethod_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { GANSSPositioningMethod_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); @@ -128,7 +128,7 @@ asn_dec_rval_t GANSSPositioningMethod_decode_uper( { GANSSPositioningMethod_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t GANSSPositioningMethod_encode_uper( diff --git a/src/core/libs/supl/asn-rrlp/GANSSRealTimeIntegrity.c b/src/core/libs/supl/asn-rrlp/GANSSRealTimeIntegrity.c index c94d255cf..c88960f58 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSRealTimeIntegrity.c +++ b/src/core/libs/supl/asn-rrlp/GANSSRealTimeIntegrity.c @@ -8,18 +8,18 @@ static asn_TYPE_member_t asn_MBR_GANSSRealTimeIntegrity_1[] = { {ATF_NOFLAGS, 0, - offsetof(struct GANSSRealTimeIntegrity, ganssBadSignalList), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfBadSignalElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssBadSignalList"}, + offsetof(struct GANSSRealTimeIntegrity, ganssBadSignalList), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfBadSignalElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssBadSignalList"}, }; static ber_tlv_tag_t asn_DEF_GANSSRealTimeIntegrity_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_GANSSRealTimeIntegrity_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0} /* ganssBadSignalList at 1295 */ + 0} /* ganssBadSignalList at 1295 */ }; static asn_SEQUENCE_specifics_t asn_SPC_GANSSRealTimeIntegrity_specs_1 = { sizeof(struct GANSSRealTimeIntegrity), @@ -51,7 +51,7 @@ asn_TYPE_descriptor_t asn_DEF_GANSSRealTimeIntegrity = { asn_DEF_GANSSRealTimeIntegrity_tags_1, /* Same as above */ sizeof(asn_DEF_GANSSRealTimeIntegrity_tags_1) / sizeof(asn_DEF_GANSSRealTimeIntegrity_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSSRealTimeIntegrity_1, 1, /* Elements count */ &asn_SPC_GANSSRealTimeIntegrity_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GANSSRefLocation.c b/src/core/libs/supl/asn-rrlp/GANSSRefLocation.c index 8dc1c8674..caf41006b 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSRefLocation.c +++ b/src/core/libs/supl/asn-rrlp/GANSSRefLocation.c @@ -8,11 +8,11 @@ static asn_TYPE_member_t asn_MBR_GANSSRefLocation_1[] = { {ATF_NOFLAGS, 0, offsetof(struct GANSSRefLocation, threeDLocation), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Ext_GeographicalInformation, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "threeDLocation"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Ext_GeographicalInformation, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "threeDLocation"}, }; static ber_tlv_tag_t asn_DEF_GANSSRefLocation_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -49,7 +49,7 @@ asn_TYPE_descriptor_t asn_DEF_GANSSRefLocation = { asn_DEF_GANSSRefLocation_tags_1, /* Same as above */ sizeof(asn_DEF_GANSSRefLocation_tags_1) / sizeof(asn_DEF_GANSSRefLocation_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSSRefLocation_1, 1, /* Elements count */ &asn_SPC_GANSSRefLocation_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GANSSRefMeasurementAssist.c b/src/core/libs/supl/asn-rrlp/GANSSRefMeasurementAssist.c index 198517df0..930a277a4 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSRefMeasurementAssist.c +++ b/src/core/libs/supl/asn-rrlp/GANSSRefMeasurementAssist.c @@ -15,7 +15,7 @@ static int memb_ganssSignalID_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ static int memb_ganssSignalID_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -42,16 +42,16 @@ static asn_per_constraints_t ASN_PER_MEMB_GANSS_SIGNAL_ID_CONSTR_2 = { }; static asn_TYPE_member_t asn_MBR_GANSSRefMeasurementAssist_1[] = { {ATF_POINTER, 1, offsetof(struct GANSSRefMeasurementAssist, ganssSignalID), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ganssSignalID_constraint_1, - &ASN_PER_MEMB_GANSS_SIGNAL_ID_CONSTR_2, 0, "ganssSignalID"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ganssSignalID_constraint_1, + &ASN_PER_MEMB_GANSS_SIGNAL_ID_CONSTR_2, 0, "ganssSignalID"}, {ATF_NOFLAGS, 0, - offsetof(struct GANSSRefMeasurementAssist, ganssRefMeasAssitList), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfGANSSRefMeasurementElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssRefMeasAssitList"}, + offsetof(struct GANSSRefMeasurementAssist, ganssRefMeasAssitList), + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfGANSSRefMeasurementElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssRefMeasAssitList"}, }; static int asn_MAP_GANSSRefMeasurementAssist_oms_1[] = {0}; static ber_tlv_tag_t asn_DEF_GANSSRefMeasurementAssist_tags_1[] = { @@ -59,7 +59,7 @@ static ber_tlv_tag_t asn_DEF_GANSSRefMeasurementAssist_tags_1[] = { static asn_TYPE_tag2member_t asn_MAP_GANSSRefMeasurementAssist_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* ganssSignalID at 1321 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0} /* ganssRefMeasAssitList at 1323 */ + 0} /* ganssRefMeasAssitList at 1323 */ }; static asn_SEQUENCE_specifics_t asn_SPC_GANSSRefMeasurementAssist_specs_1 = { sizeof(struct GANSSRefMeasurementAssist), @@ -91,7 +91,7 @@ asn_TYPE_descriptor_t asn_DEF_GANSSRefMeasurementAssist = { asn_DEF_GANSSRefMeasurementAssist_tags_1, /* Same as above */ sizeof(asn_DEF_GANSSRefMeasurementAssist_tags_1) / sizeof(asn_DEF_GANSSRefMeasurementAssist_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSSRefMeasurementAssist_1, 2, /* Elements count */ &asn_SPC_GANSSRefMeasurementAssist_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GANSSRefMeasurementAssist.h b/src/core/libs/supl/asn-rrlp/GANSSRefMeasurementAssist.h index 25b79d343..bfdfa482a 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSRefMeasurementAssist.h +++ b/src/core/libs/supl/asn-rrlp/GANSSRefMeasurementAssist.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include #include "SeqOfGANSSRefMeasurementElement.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/GANSSRefMeasurementElement.c b/src/core/libs/supl/asn-rrlp/GANSSRefMeasurementElement.c index de84afcb0..4c15149e9 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSRefMeasurementElement.c +++ b/src/core/libs/supl/asn-rrlp/GANSSRefMeasurementElement.c @@ -7,16 +7,16 @@ #include "GANSSRefMeasurementElement.h" static int memb_doppler0_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,22 +30,22 @@ static int memb_doppler0_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_codePhase_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -59,22 +59,22 @@ static int memb_codePhase_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_intCodePhase_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -88,7 +88,7 @@ static int memb_intCodePhase_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -102,7 +102,7 @@ static int memb_codePhaseSearchWindow_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -116,7 +116,7 @@ static int memb_codePhaseSearchWindow_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -147,42 +147,42 @@ static asn_per_constraints_t ASN_PER_MEMB_CODE_PHASE_SEARCH_WINDOW_CONSTR_7 = { }; static asn_TYPE_member_t asn_MBR_GANSSRefMeasurementElement_1[] = { {ATF_NOFLAGS, 0, offsetof(struct GANSSRefMeasurementElement, svID), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SVID, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "svID"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SVID, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "svID"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSRefMeasurementElement, doppler0), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_doppler0_constraint_1, - &ASN_PER_MEMB_DOPPLER0_CONSTR_3, 0, "doppler0"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_doppler0_constraint_1, + &ASN_PER_MEMB_DOPPLER0_CONSTR_3, 0, "doppler0"}, {ATF_POINTER, 1, - offsetof(struct GANSSRefMeasurementElement, additionalDoppler), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_AdditionalDopplerFields, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "additionalDoppler"}, + offsetof(struct GANSSRefMeasurementElement, additionalDoppler), + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_AdditionalDopplerFields, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "additionalDoppler"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSRefMeasurementElement, codePhase), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_codePhase_constraint_1, - &ASN_PER_MEMB_CODE_PHASE_CONSTR_5, 0, "codePhase"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_codePhase_constraint_1, + &ASN_PER_MEMB_CODE_PHASE_CONSTR_5, 0, "codePhase"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSRefMeasurementElement, intCodePhase), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_intCodePhase_constraint_1, - &ASN_PER_MEMB_INT_CODE_PHASE_CONSTR_6, 0, "intCodePhase"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_intCodePhase_constraint_1, + &ASN_PER_MEMB_INT_CODE_PHASE_CONSTR_6, 0, "intCodePhase"}, {ATF_NOFLAGS, 0, - offsetof(struct GANSSRefMeasurementElement, codePhaseSearchWindow), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_codePhaseSearchWindow_constraint_1, - &ASN_PER_MEMB_CODE_PHASE_SEARCH_WINDOW_CONSTR_7, 0, - "codePhaseSearchWindow"}, + offsetof(struct GANSSRefMeasurementElement, codePhaseSearchWindow), + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_codePhaseSearchWindow_constraint_1, + &ASN_PER_MEMB_CODE_PHASE_SEARCH_WINDOW_CONSTR_7, 0, + "codePhaseSearchWindow"}, {ATF_POINTER, 1, - offsetof(struct GANSSRefMeasurementElement, additionalAngle), - (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_AddionalAngleFields, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "additionalAngle"}, + offsetof(struct GANSSRefMeasurementElement, additionalAngle), + (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_AddionalAngleFields, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "additionalAngle"}, }; static int asn_MAP_GANSSRefMeasurementElement_oms_1[] = {2, 6}; static ber_tlv_tag_t asn_DEF_GANSSRefMeasurementElement_tags_1[] = { @@ -191,11 +191,11 @@ static asn_TYPE_tag2member_t asn_MAP_GANSSRefMeasurementElement_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* svID at 1328 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0}, /* doppler0 at 1331 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, - 0}, /* additionalDoppler at 1332 */ + 0}, /* additionalDoppler at 1332 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, 0}, /* codePhase at 1333 */ {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, 0}, /* intCodePhase at 1334 */ {(ASN_TAG_CLASS_CONTEXT | (5 << 2)), 5, 0, - 0}, /* codePhaseSearchWindow at 1335 */ + 0}, /* codePhaseSearchWindow at 1335 */ {(ASN_TAG_CLASS_CONTEXT | (6 << 2)), 6, 0, 0} /* additionalAngle at 1336 */ }; static asn_SEQUENCE_specifics_t asn_SPC_GANSSRefMeasurementElement_specs_1 = { @@ -225,10 +225,10 @@ asn_TYPE_descriptor_t asn_DEF_GANSSRefMeasurementElement = { asn_DEF_GANSSRefMeasurementElement_tags_1, sizeof(asn_DEF_GANSSRefMeasurementElement_tags_1) / sizeof(asn_DEF_GANSSRefMeasurementElement_tags_1[0]), /* 1 */ - asn_DEF_GANSSRefMeasurementElement_tags_1, /* Same as above */ + asn_DEF_GANSSRefMeasurementElement_tags_1, /* Same as above */ sizeof(asn_DEF_GANSSRefMeasurementElement_tags_1) / sizeof(asn_DEF_GANSSRefMeasurementElement_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSSRefMeasurementElement_1, 7, /* Elements count */ &asn_SPC_GANSSRefMeasurementElement_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GANSSRefMeasurementElement.h b/src/core/libs/supl/asn-rrlp/GANSSRefMeasurementElement.h index a19446648..911ecd7ac 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSRefMeasurementElement.h +++ b/src/core/libs/supl/asn-rrlp/GANSSRefMeasurementElement.h @@ -50,8 +50,8 @@ extern "C" #endif /* Referred external types */ -#include "AdditionalDopplerFields.h" #include "AddionalAngleFields.h" +#include "AdditionalDopplerFields.h" #endif /* _GANSSRefMeasurementElement_H_ */ #include diff --git a/src/core/libs/supl/asn-rrlp/GANSSRefTimeInfo.c b/src/core/libs/supl/asn-rrlp/GANSSRefTimeInfo.c index 6bfa91d9f..317785000 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSRefTimeInfo.c +++ b/src/core/libs/supl/asn-rrlp/GANSSRefTimeInfo.c @@ -7,16 +7,16 @@ #include "GANSSRefTimeInfo.h" static int memb_ganssDay_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,22 +30,22 @@ static int memb_ganssDay_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ganssTimeID_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -59,7 +59,7 @@ static int memb_ganssTimeID_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -78,24 +78,24 @@ static asn_per_constraints_t ASN_PER_MEMB_GANSS_TIME_ID_CONSTR_5 = { }; static asn_TYPE_member_t asn_MBR_GANSSRefTimeInfo_1[] = { {ATF_POINTER, 1, offsetof(struct GANSSRefTimeInfo, ganssDay), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ganssDay_constraint_1, - &ASN_PER_MEMB_GANSS_DAY_CONSTR_2, 0, "ganssDay"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ganssDay_constraint_1, + &ASN_PER_MEMB_GANSS_DAY_CONSTR_2, 0, "ganssDay"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSRefTimeInfo, ganssTOD), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSTOD, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssTOD"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSTOD, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssTOD"}, {ATF_POINTER, 2, offsetof(struct GANSSRefTimeInfo, ganssTODUncertainty), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSTODUncertainty, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssTODUncertainty"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSTODUncertainty, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssTODUncertainty"}, {ATF_POINTER, 1, offsetof(struct GANSSRefTimeInfo, ganssTimeID), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ganssTimeID_constraint_1, - &ASN_PER_MEMB_GANSS_TIME_ID_CONSTR_5, 0, "ganssTimeID"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ganssTimeID_constraint_1, + &ASN_PER_MEMB_GANSS_TIME_ID_CONSTR_5, 0, "ganssTimeID"}, }; static int asn_MAP_GANSSRefTimeInfo_oms_1[] = {0, 2, 3}; static ber_tlv_tag_t asn_DEF_GANSSRefTimeInfo_tags_1[] = { @@ -104,7 +104,7 @@ static asn_TYPE_tag2member_t asn_MAP_GANSSRefTimeInfo_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* ganssDay at 1104 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0}, /* ganssTOD at 1105 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, - 0}, /* ganssTODUncertainty at 1106 */ + 0}, /* ganssTODUncertainty at 1106 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, 0} /* ganssTimeID at 1107 */ }; static asn_SEQUENCE_specifics_t asn_SPC_GANSSRefTimeInfo_specs_1 = { @@ -137,7 +137,7 @@ asn_TYPE_descriptor_t asn_DEF_GANSSRefTimeInfo = { asn_DEF_GANSSRefTimeInfo_tags_1, /* Same as above */ sizeof(asn_DEF_GANSSRefTimeInfo_tags_1) / sizeof(asn_DEF_GANSSRefTimeInfo_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSSRefTimeInfo_1, 4, /* Elements count */ &asn_SPC_GANSSRefTimeInfo_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GANSSRefTimeInfo.h b/src/core/libs/supl/asn-rrlp/GANSSRefTimeInfo.h index cd3af9d62..959f4aa15 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSRefTimeInfo.h +++ b/src/core/libs/supl/asn-rrlp/GANSSRefTimeInfo.h @@ -10,9 +10,9 @@ #include /* Including external dependencies */ -#include #include "GANSSTOD.h" #include "GANSSTODUncertainty.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/GANSSReferenceTime.c b/src/core/libs/supl/asn-rrlp/GANSSReferenceTime.c index c00226e0a..cc41e0079 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSReferenceTime.c +++ b/src/core/libs/supl/asn-rrlp/GANSSReferenceTime.c @@ -8,27 +8,27 @@ static asn_TYPE_member_t asn_MBR_GANSSReferenceTime_1[] = { {ATF_NOFLAGS, 0, offsetof(struct GANSSReferenceTime, ganssRefTimeInfo), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSRefTimeInfo, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssRefTimeInfo"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSRefTimeInfo, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssRefTimeInfo"}, {ATF_POINTER, 1, - offsetof(struct GANSSReferenceTime, ganssTOD_GSMTimeAssociation), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSTOD_GSMTimeAssociation, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssTOD-GSMTimeAssociation"}, + offsetof(struct GANSSReferenceTime, ganssTOD_GSMTimeAssociation), + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSTOD_GSMTimeAssociation, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssTOD-GSMTimeAssociation"}, }; static int asn_MAP_GANSSReferenceTime_oms_1[] = {1}; static ber_tlv_tag_t asn_DEF_GANSSReferenceTime_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_GANSSReferenceTime_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0}, /* ganssRefTimeInfo at 1098 */ + 0}, /* ganssRefTimeInfo at 1098 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0} /* ganssTOD-GSMTimeAssociation at 1099 */ + 0} /* ganssTOD-GSMTimeAssociation at 1099 */ }; static asn_SEQUENCE_specifics_t asn_SPC_GANSSReferenceTime_specs_1 = { sizeof(struct GANSSReferenceTime), @@ -60,7 +60,7 @@ asn_TYPE_descriptor_t asn_DEF_GANSSReferenceTime = { asn_DEF_GANSSReferenceTime_tags_1, /* Same as above */ sizeof(asn_DEF_GANSSReferenceTime_tags_1) / sizeof(asn_DEF_GANSSReferenceTime_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSSReferenceTime_1, 2, /* Elements count */ &asn_SPC_GANSSReferenceTime_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GANSSSatelliteElement.c b/src/core/libs/supl/asn-rrlp/GANSSSatelliteElement.c index f362c4df7..439e2ffe8 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSSatelliteElement.c +++ b/src/core/libs/supl/asn-rrlp/GANSSSatelliteElement.c @@ -7,16 +7,16 @@ #include "GANSSSatelliteElement.h" static int memb_svHealth_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,21 +30,21 @@ static int memb_svHealth_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_iod_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -58,7 +58,7 @@ static int memb_iod_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -77,30 +77,30 @@ static asn_per_constraints_t ASN_PER_MEMB_IOD_CONSTR_4 = { }; static asn_TYPE_member_t asn_MBR_GANSSSatelliteElement_1[] = { {ATF_NOFLAGS, 0, offsetof(struct GANSSSatelliteElement, svID), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SVID, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "svID"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SVID, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "svID"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSSatelliteElement, svHealth), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_svHealth_constraint_1, - &ASN_PER_MEMB_SV_HEALTH_CONSTR_3, 0, "svHealth"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_svHealth_constraint_1, + &ASN_PER_MEMB_SV_HEALTH_CONSTR_3, 0, "svHealth"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSSatelliteElement, iod), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_iod_constraint_1, &ASN_PER_MEMB_IOD_CONSTR_4, - 0, "iod"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_iod_constraint_1, &ASN_PER_MEMB_IOD_CONSTR_4, + 0, "iod"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSSatelliteElement, ganssClockModel), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), +1, /* EXPLICIT tag at current level */ - &asn_DEF_GANSSClockModel, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssClockModel"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), +1, /* EXPLICIT tag at current level */ + &asn_DEF_GANSSClockModel, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssClockModel"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSSatelliteElement, ganssOrbitModel), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), +1, /* EXPLICIT tag at current level */ - &asn_DEF_GANSSOrbitModel, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssOrbitModel"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), +1, /* EXPLICIT tag at current level */ + &asn_DEF_GANSSOrbitModel, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssOrbitModel"}, }; static ber_tlv_tag_t asn_DEF_GANSSSatelliteElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -141,7 +141,7 @@ asn_TYPE_descriptor_t asn_DEF_GANSSSatelliteElement = { asn_DEF_GANSSSatelliteElement_tags_1, /* Same as above */ sizeof(asn_DEF_GANSSSatelliteElement_tags_1) / sizeof(asn_DEF_GANSSSatelliteElement_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSSSatelliteElement_1, 5, /* Elements count */ &asn_SPC_GANSSSatelliteElement_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GANSSSatelliteElement.h b/src/core/libs/supl/asn-rrlp/GANSSSatelliteElement.h index 92f8ec837..937600f7a 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSSatelliteElement.h +++ b/src/core/libs/supl/asn-rrlp/GANSSSatelliteElement.h @@ -10,10 +10,10 @@ #include /* Including external dependencies */ -#include "SVID.h" -#include #include "GANSSClockModel.h" #include "GANSSOrbitModel.h" +#include "SVID.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/GANSSSignalID.c b/src/core/libs/supl/asn-rrlp/GANSSSignalID.c index 2f299b49c..a9510f718 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSSignalID.c +++ b/src/core/libs/supl/asn-rrlp/GANSSSignalID.c @@ -7,15 +7,15 @@ #include "GANSSSignalID.h" int GANSSSignalID_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ int GANSSSignalID_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -56,74 +56,74 @@ static void GANSSSignalID_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void GANSSSignalID_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { GANSSSignalID_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int GANSSSignalID_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { GANSSSignalID_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t GANSSSignalID_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { GANSSSignalID_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t GANSSSignalID_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { GANSSSignalID_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t GANSSSignalID_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, const char *opt_mname, + const void *bufptr, size_t size) { GANSSSignalID_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t GANSSSignalID_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { GANSSSignalID_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t GANSSSignalID_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { GANSSSignalID_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t GANSSSignalID_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { GANSSSignalID_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/GANSSTOD-GSMTimeAssociation.c b/src/core/libs/supl/asn-rrlp/GANSSTOD-GSMTimeAssociation.c index 446ec823b..7e0e3b785 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSTOD-GSMTimeAssociation.c +++ b/src/core/libs/supl/asn-rrlp/GANSSTOD-GSMTimeAssociation.c @@ -8,37 +8,37 @@ static asn_TYPE_member_t asn_MBR_GANSSTOD_GSMTimeAssociation_1[] = { {ATF_NOFLAGS, 0, offsetof(struct GANSSTOD_GSMTimeAssociation, bcchCarrier), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BCCHCarrier, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "bcchCarrier"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BCCHCarrier, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "bcchCarrier"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSTOD_GSMTimeAssociation, bsic), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BSIC, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "bsic"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BSIC, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "bsic"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSTOD_GSMTimeAssociation, frameNumber), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_FrameNumber, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "frameNumber"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_FrameNumber, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "frameNumber"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSTOD_GSMTimeAssociation, timeSlot), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_TimeSlot, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "timeSlot"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_TimeSlot, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "timeSlot"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSTOD_GSMTimeAssociation, bitNumber), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BitNumber, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "bitNumber"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BitNumber, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "bitNumber"}, {ATF_POINTER, 1, offsetof(struct GANSSTOD_GSMTimeAssociation, frameDrift), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_FrameDrift, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "frameDrift"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_FrameDrift, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "frameDrift"}, }; static int asn_MAP_GANSSTOD_GSMTimeAssociation_oms_1[] = {5}; static ber_tlv_tag_t asn_DEF_GANSSTOD_GSMTimeAssociation_tags_1[] = { @@ -78,10 +78,10 @@ asn_TYPE_descriptor_t asn_DEF_GANSSTOD_GSMTimeAssociation = { asn_DEF_GANSSTOD_GSMTimeAssociation_tags_1, sizeof(asn_DEF_GANSSTOD_GSMTimeAssociation_tags_1) / sizeof(asn_DEF_GANSSTOD_GSMTimeAssociation_tags_1[0]), /* 1 */ - asn_DEF_GANSSTOD_GSMTimeAssociation_tags_1, /* Same as above */ + asn_DEF_GANSSTOD_GSMTimeAssociation_tags_1, /* Same as above */ sizeof(asn_DEF_GANSSTOD_GSMTimeAssociation_tags_1) / sizeof(asn_DEF_GANSSTOD_GSMTimeAssociation_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSSTOD_GSMTimeAssociation_1, 6, /* Elements count */ &asn_SPC_GANSSTOD_GSMTimeAssociation_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GANSSTOD-GSMTimeAssociation.h b/src/core/libs/supl/asn-rrlp/GANSSTOD-GSMTimeAssociation.h index 001741c41..7fb1d0099 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSTOD-GSMTimeAssociation.h +++ b/src/core/libs/supl/asn-rrlp/GANSSTOD-GSMTimeAssociation.h @@ -12,10 +12,10 @@ /* Including external dependencies */ #include "BCCHCarrier.h" #include "BSIC.h" -#include "FrameNumber.h" -#include "TimeSlot.h" #include "BitNumber.h" #include "FrameDrift.h" +#include "FrameNumber.h" +#include "TimeSlot.h" #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/GANSSTOD.c b/src/core/libs/supl/asn-rrlp/GANSSTOD.c index 350b46d82..b6a69783c 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSTOD.c +++ b/src/core/libs/supl/asn-rrlp/GANSSTOD.c @@ -7,14 +7,14 @@ #include "GANSSTOD.h" int GANSSTOD_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int GANSSTOD_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -55,68 +55,68 @@ static void GANSSTOD_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void GANSSTOD_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { GANSSTOD_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int GANSSTOD_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { GANSSTOD_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t GANSSTOD_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, + int tag_mode) { GANSSTOD_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t GANSSTOD_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { GANSSTOD_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t GANSSTOD_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { GANSSTOD_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t GANSSTOD_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { GANSSTOD_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t GANSSTOD_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { GANSSTOD_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t GANSSTOD_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { GANSSTOD_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/GANSSTODUncertainty.c b/src/core/libs/supl/asn-rrlp/GANSSTODUncertainty.c index 0d5f36b88..f8fe5902c 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSTODUncertainty.c +++ b/src/core/libs/supl/asn-rrlp/GANSSTODUncertainty.c @@ -7,15 +7,15 @@ #include "GANSSTODUncertainty.h" int GANSSTODUncertainty_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ int GANSSTODUncertainty_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -57,57 +57,57 @@ static void GANSSTODUncertainty_1_inherit_TYPE_descriptor( } void GANSSTODUncertainty_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { GANSSTODUncertainty_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int GANSSTODUncertainty_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, + void *app_key) { GANSSTODUncertainty_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t GANSSTODUncertainty_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, + const void *bufptr, size_t size, + int tag_mode) { GANSSTODUncertainty_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t GANSSTODUncertainty_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { GANSSTODUncertainty_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t GANSSTODUncertainty_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { GANSSTODUncertainty_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t GANSSTODUncertainty_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { GANSSTODUncertainty_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); @@ -120,7 +120,7 @@ asn_dec_rval_t GANSSTODUncertainty_decode_uper( { GANSSTODUncertainty_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t GANSSTODUncertainty_encode_uper( diff --git a/src/core/libs/supl/asn-rrlp/GANSSTODm.c b/src/core/libs/supl/asn-rrlp/GANSSTODm.c index b4c51052d..1cc425018 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSTODm.c +++ b/src/core/libs/supl/asn-rrlp/GANSSTODm.c @@ -7,14 +7,14 @@ #include "GANSSTODm.h" int GANSSTODm_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int GANSSTODm_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -55,68 +55,68 @@ static void GANSSTODm_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void GANSSTODm_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { GANSSTODm_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int GANSSTODm_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { GANSSTODm_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t GANSSTODm_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, + int tag_mode) { GANSSTODm_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t GANSSTODm_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { GANSSTODm_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t GANSSTODm_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { GANSSTODm_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t GANSSTODm_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { GANSSTODm_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t GANSSTODm_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { GANSSTODm_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t GANSSTODm_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { GANSSTODm_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/GANSSTimeModelElement.c b/src/core/libs/supl/asn-rrlp/GANSSTimeModelElement.c index 78c662bab..4d91c946c 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSTimeModelElement.c +++ b/src/core/libs/supl/asn-rrlp/GANSSTimeModelElement.c @@ -15,7 +15,7 @@ static int memb_ganssTimeModelRefTime_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,22 +29,22 @@ static int memb_ganssTimeModelRefTime_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_gnssTOID_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -58,22 +58,22 @@ static int memb_gnssTOID_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_weekNumber_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -87,7 +87,7 @@ static int memb_weekNumber_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -112,41 +112,41 @@ static asn_per_constraints_t ASN_PER_MEMB_WEEK_NUMBER_CONSTR_7 = { }; static asn_TYPE_member_t asn_MBR_GANSSTimeModelElement_1[] = { {ATF_NOFLAGS, 0, - offsetof(struct GANSSTimeModelElement, ganssTimeModelRefTime), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ganssTimeModelRefTime_constraint_1, - &ASN_PER_MEMB_GANSS_TIME_MODEL_REF_TIME_CONSTR_2, 0, - "ganssTimeModelRefTime"}, + offsetof(struct GANSSTimeModelElement, ganssTimeModelRefTime), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ganssTimeModelRefTime_constraint_1, + &ASN_PER_MEMB_GANSS_TIME_MODEL_REF_TIME_CONSTR_2, 0, + "ganssTimeModelRefTime"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSTimeModelElement, tA0), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_TA0, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "tA0"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_TA0, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "tA0"}, {ATF_POINTER, 2, offsetof(struct GANSSTimeModelElement, tA1), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_TA1, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "tA1"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_TA1, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "tA1"}, {ATF_POINTER, 1, offsetof(struct GANSSTimeModelElement, tA2), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_TA2, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "tA2"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_TA2, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "tA2"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSTimeModelElement, gnssTOID), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_gnssTOID_constraint_1, - &ASN_PER_MEMB_GNSS_TOID_CONSTR_6, 0, "gnssTOID"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_gnssTOID_constraint_1, + &ASN_PER_MEMB_GNSS_TOID_CONSTR_6, 0, "gnssTOID"}, {ATF_POINTER, 1, offsetof(struct GANSSTimeModelElement, weekNumber), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_weekNumber_constraint_1, - &ASN_PER_MEMB_WEEK_NUMBER_CONSTR_7, 0, "weekNumber"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_weekNumber_constraint_1, + &ASN_PER_MEMB_WEEK_NUMBER_CONSTR_7, 0, "weekNumber"}, }; static int asn_MAP_GANSSTimeModelElement_oms_1[] = {2, 3, 5}; static ber_tlv_tag_t asn_DEF_GANSSTimeModelElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_GANSSTimeModelElement_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0}, /* ganssTimeModelRefTime at 1167 */ + 0}, /* ganssTimeModelRefTime at 1167 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0}, /* tA0 at 1168 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0}, /* tA1 at 1169 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, 0}, /* tA2 at 1170 */ @@ -183,7 +183,7 @@ asn_TYPE_descriptor_t asn_DEF_GANSSTimeModelElement = { asn_DEF_GANSSTimeModelElement_tags_1, /* Same as above */ sizeof(asn_DEF_GANSSTimeModelElement_tags_1) / sizeof(asn_DEF_GANSSTimeModelElement_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSSTimeModelElement_1, 6, /* Elements count */ &asn_SPC_GANSSTimeModelElement_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GANSSTimeModelElement.h b/src/core/libs/supl/asn-rrlp/GANSSTimeModelElement.h index fd67d57c9..6784f5e19 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSTimeModelElement.h +++ b/src/core/libs/supl/asn-rrlp/GANSSTimeModelElement.h @@ -10,10 +10,10 @@ #include /* Including external dependencies */ -#include #include "TA0.h" #include "TA1.h" #include "TA2.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/GANSSUTCModel.c b/src/core/libs/supl/asn-rrlp/GANSSUTCModel.c index e943a5b26..05d2b79ab 100644 --- a/src/core/libs/supl/asn-rrlp/GANSSUTCModel.c +++ b/src/core/libs/supl/asn-rrlp/GANSSUTCModel.c @@ -7,16 +7,16 @@ #include "GANSSUTCModel.h" static int memb_ganssUtcA1_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,22 +30,22 @@ static int memb_ganssUtcA1_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ganssUtcA0_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -59,22 +59,22 @@ static int memb_ganssUtcA0_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ganssUtcTot_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -88,22 +88,22 @@ static int memb_ganssUtcTot_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ganssUtcWNt_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -117,7 +117,7 @@ static int memb_ganssUtcWNt_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -131,7 +131,7 @@ static int memb_ganssUtcDeltaTls_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -145,7 +145,7 @@ static int memb_ganssUtcDeltaTls_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -159,7 +159,7 @@ static int memb_ganssUtcWNlsf_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -173,22 +173,22 @@ static int memb_ganssUtcWNlsf_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ganssUtcDN_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -202,7 +202,7 @@ static int memb_ganssUtcDN_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -216,7 +216,7 @@ static int memb_ganssUtcDeltaTlsf_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -230,7 +230,7 @@ static int memb_ganssUtcDeltaTlsf_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -243,7 +243,7 @@ static asn_per_constraints_t ASN_PER_MEMB_GANSS_UTC_A1_CONSTR_2 = { }; static asn_per_constraints_t ASN_PER_MEMB_GANSS_UTC_A0_CONSTR_3 = { {APC_CONSTRAINED, 32, -1, (-2147483647L - 1), - 2147483647} /* (-2147483648..2147483647) */, + 2147483647} /* (-2147483648..2147483647) */, {APC_UNCONSTRAINED, -1, -1, 0, 0}, 0, 0 /* No PER value map */ @@ -286,37 +286,37 @@ static asn_per_constraints_t ASN_PER_MEMB_GANSS_UTC_DELTA_TLSF_CONSTR_9 = { }; static asn_TYPE_member_t asn_MBR_GANSSUTCModel_1[] = { {ATF_NOFLAGS, 0, offsetof(struct GANSSUTCModel, ganssUtcA1), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ganssUtcA1_constraint_1, - &ASN_PER_MEMB_GANSS_UTC_A1_CONSTR_2, 0, "ganssUtcA1"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ganssUtcA1_constraint_1, + &ASN_PER_MEMB_GANSS_UTC_A1_CONSTR_2, 0, "ganssUtcA1"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSUTCModel, ganssUtcA0), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ganssUtcA0_constraint_1, - &ASN_PER_MEMB_GANSS_UTC_A0_CONSTR_3, 0, "ganssUtcA0"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ganssUtcA0_constraint_1, + &ASN_PER_MEMB_GANSS_UTC_A0_CONSTR_3, 0, "ganssUtcA0"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSUTCModel, ganssUtcTot), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ganssUtcTot_constraint_1, - &ASN_PER_MEMB_GANSS_UTC_TOT_CONSTR_4, 0, "ganssUtcTot"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ganssUtcTot_constraint_1, + &ASN_PER_MEMB_GANSS_UTC_TOT_CONSTR_4, 0, "ganssUtcTot"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSUTCModel, ganssUtcWNt), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ganssUtcWNt_constraint_1, - &ASN_PER_MEMB_GANSS_UTC_W_NT_CONSTR_5, 0, "ganssUtcWNt"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ganssUtcWNt_constraint_1, + &ASN_PER_MEMB_GANSS_UTC_W_NT_CONSTR_5, 0, "ganssUtcWNt"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSUTCModel, ganssUtcDeltaTls), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ganssUtcDeltaTls_constraint_1, - &ASN_PER_MEMB_GANSS_UTC_DELTA_TLS_CONSTR_6, 0, "ganssUtcDeltaTls"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ganssUtcDeltaTls_constraint_1, + &ASN_PER_MEMB_GANSS_UTC_DELTA_TLS_CONSTR_6, 0, "ganssUtcDeltaTls"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSUTCModel, ganssUtcWNlsf), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ganssUtcWNlsf_constraint_1, - &ASN_PER_MEMB_GANSS_UTC_W_NLSF_CONSTR_7, 0, "ganssUtcWNlsf"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ganssUtcWNlsf_constraint_1, + &ASN_PER_MEMB_GANSS_UTC_W_NLSF_CONSTR_7, 0, "ganssUtcWNlsf"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSUTCModel, ganssUtcDN), - (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ganssUtcDN_constraint_1, - &ASN_PER_MEMB_GANSS_UTC_DN_CONSTR_8, 0, "ganssUtcDN"}, + (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ganssUtcDN_constraint_1, + &ASN_PER_MEMB_GANSS_UTC_DN_CONSTR_8, 0, "ganssUtcDN"}, {ATF_NOFLAGS, 0, offsetof(struct GANSSUTCModel, ganssUtcDeltaTlsf), - (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ganssUtcDeltaTlsf_constraint_1, - &ASN_PER_MEMB_GANSS_UTC_DELTA_TLSF_CONSTR_9, 0, "ganssUtcDeltaTlsf"}, + (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ganssUtcDeltaTlsf_constraint_1, + &ASN_PER_MEMB_GANSS_UTC_DELTA_TLSF_CONSTR_9, 0, "ganssUtcDeltaTlsf"}, }; static ber_tlv_tag_t asn_DEF_GANSSUTCModel_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -326,11 +326,11 @@ static asn_TYPE_tag2member_t asn_MAP_GANSSUTCModel_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0}, /* ganssUtcTot at 1384 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, 0}, /* ganssUtcWNt at 1385 */ {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, - 0}, /* ganssUtcDeltaTls at 1386 */ + 0}, /* ganssUtcDeltaTls at 1386 */ {(ASN_TAG_CLASS_CONTEXT | (5 << 2)), 5, 0, 0}, /* ganssUtcWNlsf at 1387 */ {(ASN_TAG_CLASS_CONTEXT | (6 << 2)), 6, 0, 0}, /* ganssUtcDN at 1388 */ {(ASN_TAG_CLASS_CONTEXT | (7 << 2)), 7, 0, - 0} /* ganssUtcDeltaTlsf at 1389 */ + 0} /* ganssUtcDeltaTlsf at 1389 */ }; static asn_SEQUENCE_specifics_t asn_SPC_GANSSUTCModel_specs_1 = { sizeof(struct GANSSUTCModel), @@ -362,7 +362,7 @@ asn_TYPE_descriptor_t asn_DEF_GANSSUTCModel = { asn_DEF_GANSSUTCModel_tags_1, /* Same as above */ sizeof(asn_DEF_GANSSUTCModel_tags_1) / sizeof(asn_DEF_GANSSUTCModel_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GANSSUTCModel_1, 8, /* Elements count */ &asn_SPC_GANSSUTCModel_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GPS-AssistData.c b/src/core/libs/supl/asn-rrlp/GPS-AssistData.c index e9421d0d8..4db1dc8b3 100644 --- a/src/core/libs/supl/asn-rrlp/GPS-AssistData.c +++ b/src/core/libs/supl/asn-rrlp/GPS-AssistData.c @@ -8,11 +8,11 @@ static asn_TYPE_member_t asn_MBR_GPS_AssistData_1[] = { {ATF_NOFLAGS, 0, offsetof(struct GPS_AssistData, controlHeader), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_ControlHeader, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "controlHeader"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_ControlHeader, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "controlHeader"}, }; static ber_tlv_tag_t asn_DEF_GPS_AssistData_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -49,7 +49,7 @@ asn_TYPE_descriptor_t asn_DEF_GPS_AssistData = { asn_DEF_GPS_AssistData_tags_1, /* Same as above */ sizeof(asn_DEF_GPS_AssistData_tags_1) / sizeof(asn_DEF_GPS_AssistData_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GPS_AssistData_1, 1, /* Elements count */ &asn_SPC_GPS_AssistData_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GPS-MeasureInfo.c b/src/core/libs/supl/asn-rrlp/GPS-MeasureInfo.c index 30bb4b60b..f8e8d466e 100644 --- a/src/core/libs/supl/asn-rrlp/GPS-MeasureInfo.c +++ b/src/core/libs/supl/asn-rrlp/GPS-MeasureInfo.c @@ -8,11 +8,11 @@ static asn_TYPE_member_t asn_MBR_GPS_MeasureInfo_1[] = { {ATF_NOFLAGS, 0, offsetof(struct GPS_MeasureInfo, gpsMsrSetList), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfGPS_MsrSetElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "gpsMsrSetList"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfGPS_MsrSetElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "gpsMsrSetList"}, }; static ber_tlv_tag_t asn_DEF_GPS_MeasureInfo_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -49,7 +49,7 @@ asn_TYPE_descriptor_t asn_DEF_GPS_MeasureInfo = { asn_DEF_GPS_MeasureInfo_tags_1, /* Same as above */ sizeof(asn_DEF_GPS_MeasureInfo_tags_1) / sizeof(asn_DEF_GPS_MeasureInfo_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GPS_MeasureInfo_1, 1, /* Elements count */ &asn_SPC_GPS_MeasureInfo_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GPS-MsrElement.c b/src/core/libs/supl/asn-rrlp/GPS-MsrElement.c index 7ff02fdc1..b097b7d21 100644 --- a/src/core/libs/supl/asn-rrlp/GPS-MsrElement.c +++ b/src/core/libs/supl/asn-rrlp/GPS-MsrElement.c @@ -7,15 +7,15 @@ #include "GPS-MsrElement.h" static int memb_cNo_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,22 +29,22 @@ static int memb_cNo_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_doppler_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -58,22 +58,22 @@ static int memb_doppler_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_wholeChips_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -87,22 +87,22 @@ static int memb_wholeChips_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_fracChips_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -116,7 +116,7 @@ static int memb_fracChips_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -130,7 +130,7 @@ static int memb_pseuRangeRMSErr_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -144,7 +144,7 @@ static int memb_pseuRangeRMSErr_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -181,36 +181,36 @@ static asn_per_constraints_t ASN_PER_MEMB_PSEU_RANGE_RMS_ERR_CONSTR_8 = { }; static asn_TYPE_member_t asn_MBR_GPS_MsrElement_1[] = { {ATF_NOFLAGS, 0, offsetof(struct GPS_MsrElement, satelliteID), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SatelliteID, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "satelliteID"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SatelliteID, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "satelliteID"}, {ATF_NOFLAGS, 0, offsetof(struct GPS_MsrElement, cNo), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_cNo_constraint_1, &ASN_PER_MEMB_C_NO_CONSTR_3, - 0, "cNo"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_cNo_constraint_1, &ASN_PER_MEMB_C_NO_CONSTR_3, + 0, "cNo"}, {ATF_NOFLAGS, 0, offsetof(struct GPS_MsrElement, doppler), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_doppler_constraint_1, - &ASN_PER_MEMB_DOPPLER_CONSTR_4, 0, "doppler"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_doppler_constraint_1, + &ASN_PER_MEMB_DOPPLER_CONSTR_4, 0, "doppler"}, {ATF_NOFLAGS, 0, offsetof(struct GPS_MsrElement, wholeChips), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_wholeChips_constraint_1, - &ASN_PER_MEMB_WHOLE_CHIPS_CONSTR_5, 0, "wholeChips"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_wholeChips_constraint_1, + &ASN_PER_MEMB_WHOLE_CHIPS_CONSTR_5, 0, "wholeChips"}, {ATF_NOFLAGS, 0, offsetof(struct GPS_MsrElement, fracChips), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_fracChips_constraint_1, - &ASN_PER_MEMB_FRAC_CHIPS_CONSTR_6, 0, "fracChips"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_fracChips_constraint_1, + &ASN_PER_MEMB_FRAC_CHIPS_CONSTR_6, 0, "fracChips"}, {ATF_NOFLAGS, 0, offsetof(struct GPS_MsrElement, mpathIndic), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_MpathIndic, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "mpathIndic"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_MpathIndic, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "mpathIndic"}, {ATF_NOFLAGS, 0, offsetof(struct GPS_MsrElement, pseuRangeRMSErr), - (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_pseuRangeRMSErr_constraint_1, - &ASN_PER_MEMB_PSEU_RANGE_RMS_ERR_CONSTR_8, 0, "pseuRangeRMSErr"}, + (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_pseuRangeRMSErr_constraint_1, + &ASN_PER_MEMB_PSEU_RANGE_RMS_ERR_CONSTR_8, 0, "pseuRangeRMSErr"}, }; static ber_tlv_tag_t asn_DEF_GPS_MsrElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -253,7 +253,7 @@ asn_TYPE_descriptor_t asn_DEF_GPS_MsrElement = { asn_DEF_GPS_MsrElement_tags_1, /* Same as above */ sizeof(asn_DEF_GPS_MsrElement_tags_1) / sizeof(asn_DEF_GPS_MsrElement_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GPS_MsrElement_1, 7, /* Elements count */ &asn_SPC_GPS_MsrElement_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GPS-MsrElement.h b/src/core/libs/supl/asn-rrlp/GPS-MsrElement.h index 1df83c8f9..0ceb48b4c 100644 --- a/src/core/libs/supl/asn-rrlp/GPS-MsrElement.h +++ b/src/core/libs/supl/asn-rrlp/GPS-MsrElement.h @@ -10,9 +10,9 @@ #include /* Including external dependencies */ +#include "MpathIndic.h" #include "SatelliteID.h" #include -#include "MpathIndic.h" #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/GPS-MsrSetElement.c b/src/core/libs/supl/asn-rrlp/GPS-MsrSetElement.c index d0b1fea43..9c4ea4666 100644 --- a/src/core/libs/supl/asn-rrlp/GPS-MsrSetElement.c +++ b/src/core/libs/supl/asn-rrlp/GPS-MsrSetElement.c @@ -7,16 +7,16 @@ #include "GPS-MsrSetElement.h" static int memb_refFrame_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,7 +30,7 @@ static int memb_refFrame_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -43,20 +43,20 @@ static asn_per_constraints_t ASN_PER_MEMB_REF_FRAME_CONSTR_2 = { }; static asn_TYPE_member_t asn_MBR_GPS_MsrSetElement_1[] = { {ATF_POINTER, 1, offsetof(struct GPS_MsrSetElement, refFrame), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_refFrame_constraint_1, - &ASN_PER_MEMB_REF_FRAME_CONSTR_2, 0, "refFrame"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_refFrame_constraint_1, + &ASN_PER_MEMB_REF_FRAME_CONSTR_2, 0, "refFrame"}, {ATF_NOFLAGS, 0, offsetof(struct GPS_MsrSetElement, gpsTOW), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GPSTOW24b, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "gpsTOW"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GPSTOW24b, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "gpsTOW"}, {ATF_NOFLAGS, 0, offsetof(struct GPS_MsrSetElement, gps_msrList), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfGPS_MsrElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "gps-msrList"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfGPS_MsrElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "gps-msrList"}, }; static int asn_MAP_GPS_MsrSetElement_oms_1[] = {0}; static ber_tlv_tag_t asn_DEF_GPS_MsrSetElement_tags_1[] = { @@ -96,7 +96,7 @@ asn_TYPE_descriptor_t asn_DEF_GPS_MsrSetElement = { asn_DEF_GPS_MsrSetElement_tags_1, /* Same as above */ sizeof(asn_DEF_GPS_MsrSetElement_tags_1) / sizeof(asn_DEF_GPS_MsrSetElement_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GPS_MsrSetElement_1, 3, /* Elements count */ &asn_SPC_GPS_MsrSetElement_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GPS-MsrSetElement.h b/src/core/libs/supl/asn-rrlp/GPS-MsrSetElement.h index b9ba63dad..37e284e86 100644 --- a/src/core/libs/supl/asn-rrlp/GPS-MsrSetElement.h +++ b/src/core/libs/supl/asn-rrlp/GPS-MsrSetElement.h @@ -10,9 +10,9 @@ #include /* Including external dependencies */ -#include #include "GPSTOW24b.h" #include "SeqOfGPS-MsrElement.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/GPSAssistanceData.c b/src/core/libs/supl/asn-rrlp/GPSAssistanceData.c index 55e7d7e1f..bc085b311 100644 --- a/src/core/libs/supl/asn-rrlp/GPSAssistanceData.c +++ b/src/core/libs/supl/asn-rrlp/GPSAssistanceData.c @@ -7,8 +7,8 @@ #include "GPSAssistanceData.h" int GPSAssistanceData_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const OCTET_STRING_t *st = (const OCTET_STRING_t *)sptr; size_t size; @@ -16,7 +16,7 @@ int GPSAssistanceData_constraint(asn_TYPE_descriptor_t *td, const void *sptr, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,7 +30,7 @@ int GPSAssistanceData_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -58,77 +58,77 @@ static void GPSAssistanceData_1_inherit_TYPE_descriptor( } void GPSAssistanceData_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { GPSAssistanceData_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int GPSAssistanceData_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, + void *app_key) { GPSAssistanceData_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t GPSAssistanceData_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, + const void *bufptr, size_t size, + int tag_mode) { GPSAssistanceData_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t GPSAssistanceData_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { GPSAssistanceData_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t GPSAssistanceData_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { GPSAssistanceData_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t GPSAssistanceData_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { GPSAssistanceData_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t GPSAssistanceData_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { GPSAssistanceData_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t GPSAssistanceData_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { GPSAssistanceData_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/GPSReferenceTimeUncertainty.c b/src/core/libs/supl/asn-rrlp/GPSReferenceTimeUncertainty.c index 20b54dc1b..6eba8005f 100644 --- a/src/core/libs/supl/asn-rrlp/GPSReferenceTimeUncertainty.c +++ b/src/core/libs/supl/asn-rrlp/GPSReferenceTimeUncertainty.c @@ -15,7 +15,7 @@ int GPSReferenceTimeUncertainty_constraint( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ int GPSReferenceTimeUncertainty_constraint( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -57,16 +57,16 @@ static void GPSReferenceTimeUncertainty_1_inherit_TYPE_descriptor( } void GPSReferenceTimeUncertainty_free(asn_TYPE_descriptor_t *td, - void *struct_ptr, int contents_only) + void *struct_ptr, int contents_only) { GPSReferenceTimeUncertainty_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int GPSReferenceTimeUncertainty_print(asn_TYPE_descriptor_t *td, - const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, - void *app_key) + const void *struct_ptr, int ilevel, + asn_app_consume_bytes_f *cb, + void *app_key) { GPSReferenceTimeUncertainty_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); @@ -78,7 +78,7 @@ asn_dec_rval_t GPSReferenceTimeUncertainty_decode_ber( { GPSReferenceTimeUncertainty_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t GPSReferenceTimeUncertainty_encode_der( @@ -95,7 +95,7 @@ asn_dec_rval_t GPSReferenceTimeUncertainty_decode_xer( { GPSReferenceTimeUncertainty_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t GPSReferenceTimeUncertainty_encode_xer( @@ -113,7 +113,7 @@ asn_dec_rval_t GPSReferenceTimeUncertainty_decode_uper( { GPSReferenceTimeUncertainty_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t GPSReferenceTimeUncertainty_encode_uper( @@ -149,7 +149,7 @@ asn_TYPE_descriptor_t asn_DEF_GPSReferenceTimeUncertainty = { asn_DEF_GPSReferenceTimeUncertainty_tags_1, sizeof(asn_DEF_GPSReferenceTimeUncertainty_tags_1) / sizeof(asn_DEF_GPSReferenceTimeUncertainty_tags_1[0]), /* 1 */ - asn_DEF_GPSReferenceTimeUncertainty_tags_1, /* Same as above */ + asn_DEF_GPSReferenceTimeUncertainty_tags_1, /* Same as above */ sizeof(asn_DEF_GPSReferenceTimeUncertainty_tags_1) / sizeof(asn_DEF_GPSReferenceTimeUncertainty_tags_1[0]), /* 1 */ &ASN_PER_TYPE_GPS_REFERENCE_TIME_UNCERTAINTY_CONSTR_1, diff --git a/src/core/libs/supl/asn-rrlp/GPSTOW23b.c b/src/core/libs/supl/asn-rrlp/GPSTOW23b.c index b5f776ec9..ba573ffa1 100644 --- a/src/core/libs/supl/asn-rrlp/GPSTOW23b.c +++ b/src/core/libs/supl/asn-rrlp/GPSTOW23b.c @@ -7,14 +7,14 @@ #include "GPSTOW23b.h" int GPSTOW23b_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int GPSTOW23b_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -55,68 +55,68 @@ static void GPSTOW23b_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void GPSTOW23b_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { GPSTOW23b_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int GPSTOW23b_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { GPSTOW23b_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t GPSTOW23b_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, + int tag_mode) { GPSTOW23b_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t GPSTOW23b_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { GPSTOW23b_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t GPSTOW23b_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { GPSTOW23b_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t GPSTOW23b_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { GPSTOW23b_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t GPSTOW23b_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { GPSTOW23b_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t GPSTOW23b_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { GPSTOW23b_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/GPSTOW24b.c b/src/core/libs/supl/asn-rrlp/GPSTOW24b.c index c4ba18751..28a1fe9f6 100644 --- a/src/core/libs/supl/asn-rrlp/GPSTOW24b.c +++ b/src/core/libs/supl/asn-rrlp/GPSTOW24b.c @@ -7,14 +7,14 @@ #include "GPSTOW24b.h" int GPSTOW24b_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int GPSTOW24b_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -55,68 +55,68 @@ static void GPSTOW24b_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void GPSTOW24b_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { GPSTOW24b_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int GPSTOW24b_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { GPSTOW24b_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t GPSTOW24b_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, + int tag_mode) { GPSTOW24b_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t GPSTOW24b_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { GPSTOW24b_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t GPSTOW24b_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { GPSTOW24b_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t GPSTOW24b_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { GPSTOW24b_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t GPSTOW24b_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { GPSTOW24b_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t GPSTOW24b_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { GPSTOW24b_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/GPSTOWAssist.c b/src/core/libs/supl/asn-rrlp/GPSTOWAssist.c index 09d2ec7dc..62e375c79 100644 --- a/src/core/libs/supl/asn-rrlp/GPSTOWAssist.c +++ b/src/core/libs/supl/asn-rrlp/GPSTOWAssist.c @@ -14,10 +14,10 @@ static asn_per_constraints_t ASN_PER_TYPE_GPSTOW_ASSIST_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_GPSTOWAssist_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_GPSTOWAssistElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_GPSTOWAssistElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_GPSTOWAssist_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/GPSTOWAssistElement.c b/src/core/libs/supl/asn-rrlp/GPSTOWAssistElement.c index e6db25efd..9362530d7 100644 --- a/src/core/libs/supl/asn-rrlp/GPSTOWAssistElement.c +++ b/src/core/libs/supl/asn-rrlp/GPSTOWAssistElement.c @@ -8,33 +8,33 @@ static asn_TYPE_member_t asn_MBR_GPSTOWAssistElement_1[] = { {ATF_NOFLAGS, 0, offsetof(struct GPSTOWAssistElement, satelliteID), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SatelliteID, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "satelliteID"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SatelliteID, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "satelliteID"}, {ATF_NOFLAGS, 0, offsetof(struct GPSTOWAssistElement, tlmWord), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_TLMWord, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "tlmWord"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_TLMWord, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "tlmWord"}, {ATF_NOFLAGS, 0, offsetof(struct GPSTOWAssistElement, antiSpoof), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_AntiSpoofFlag, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "antiSpoof"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_AntiSpoofFlag, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "antiSpoof"}, {ATF_NOFLAGS, 0, offsetof(struct GPSTOWAssistElement, alert), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_AlertFlag, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "alert"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_AlertFlag, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "alert"}, {ATF_NOFLAGS, 0, offsetof(struct GPSTOWAssistElement, tlmRsvdBits), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_TLMReservedBits, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "tlmRsvdBits"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_TLMReservedBits, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "tlmRsvdBits"}, }; static ber_tlv_tag_t asn_DEF_GPSTOWAssistElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -75,7 +75,7 @@ asn_TYPE_descriptor_t asn_DEF_GPSTOWAssistElement = { asn_DEF_GPSTOWAssistElement_tags_1, /* Same as above */ sizeof(asn_DEF_GPSTOWAssistElement_tags_1) / sizeof(asn_DEF_GPSTOWAssistElement_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GPSTOWAssistElement_1, 5, /* Elements count */ &asn_SPC_GPSTOWAssistElement_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GPSTOWAssistElement.h b/src/core/libs/supl/asn-rrlp/GPSTOWAssistElement.h index c8074077a..cd593c499 100644 --- a/src/core/libs/supl/asn-rrlp/GPSTOWAssistElement.h +++ b/src/core/libs/supl/asn-rrlp/GPSTOWAssistElement.h @@ -10,11 +10,11 @@ #include /* Including external dependencies */ -#include "SatelliteID.h" -#include "TLMWord.h" -#include "AntiSpoofFlag.h" #include "AlertFlag.h" +#include "AntiSpoofFlag.h" +#include "SatelliteID.h" #include "TLMReservedBits.h" +#include "TLMWord.h" #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/GPSTime.c b/src/core/libs/supl/asn-rrlp/GPSTime.c index 5c7c35b9f..7dd448a1c 100644 --- a/src/core/libs/supl/asn-rrlp/GPSTime.c +++ b/src/core/libs/supl/asn-rrlp/GPSTime.c @@ -8,15 +8,15 @@ static asn_TYPE_member_t asn_MBR_GPSTime_1[] = { {ATF_NOFLAGS, 0, offsetof(struct GPSTime, gpsTOW23b), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GPSTOW23b, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "gpsTOW23b"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GPSTOW23b, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "gpsTOW23b"}, {ATF_NOFLAGS, 0, offsetof(struct GPSTime, gpsWeek), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GPSWeek, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "gpsWeek"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GPSWeek, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "gpsWeek"}, }; static ber_tlv_tag_t asn_DEF_GPSTime_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -50,9 +50,9 @@ asn_TYPE_descriptor_t asn_DEF_GPSTime = { 0, /* Use generic outmost tag fetcher */ asn_DEF_GPSTime_tags_1, sizeof(asn_DEF_GPSTime_tags_1) / sizeof(asn_DEF_GPSTime_tags_1[0]), /* 1 */ - asn_DEF_GPSTime_tags_1, /* Same as above */ + asn_DEF_GPSTime_tags_1, /* Same as above */ sizeof(asn_DEF_GPSTime_tags_1) / sizeof(asn_DEF_GPSTime_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GPSTime_1, 2, /* Elements count */ &asn_SPC_GPSTime_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GPSTimeAssistanceMeasurements.c b/src/core/libs/supl/asn-rrlp/GPSTimeAssistanceMeasurements.c index e0f208e5c..b6be06eb7 100644 --- a/src/core/libs/supl/asn-rrlp/GPSTimeAssistanceMeasurements.c +++ b/src/core/libs/supl/asn-rrlp/GPSTimeAssistanceMeasurements.c @@ -15,7 +15,7 @@ static int memb_referenceFrameMSB_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,22 +29,22 @@ static int memb_referenceFrameMSB_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_gpsTowSubms_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -58,22 +58,22 @@ static int memb_gpsTowSubms_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_deltaTow_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -87,7 +87,7 @@ static int memb_deltaTow_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -112,27 +112,27 @@ static asn_per_constraints_t ASN_PER_MEMB_DELTA_TOW_CONSTR_4 = { }; static asn_TYPE_member_t asn_MBR_GPSTimeAssistanceMeasurements_1[] = { {ATF_NOFLAGS, 0, - offsetof(struct GPSTimeAssistanceMeasurements, referenceFrameMSB), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_referenceFrameMSB_constraint_1, - &ASN_PER_MEMB_REFERENCE_FRAME_MSB_CONSTR_2, 0, "referenceFrameMSB"}, + offsetof(struct GPSTimeAssistanceMeasurements, referenceFrameMSB), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_referenceFrameMSB_constraint_1, + &ASN_PER_MEMB_REFERENCE_FRAME_MSB_CONSTR_2, 0, "referenceFrameMSB"}, {ATF_POINTER, 3, - offsetof(struct GPSTimeAssistanceMeasurements, gpsTowSubms), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_gpsTowSubms_constraint_1, - &ASN_PER_MEMB_GPS_TOW_SUBMS_CONSTR_3, 0, "gpsTowSubms"}, + offsetof(struct GPSTimeAssistanceMeasurements, gpsTowSubms), + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_gpsTowSubms_constraint_1, + &ASN_PER_MEMB_GPS_TOW_SUBMS_CONSTR_3, 0, "gpsTowSubms"}, {ATF_POINTER, 2, offsetof(struct GPSTimeAssistanceMeasurements, deltaTow), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_deltaTow_constraint_1, - &ASN_PER_MEMB_DELTA_TOW_CONSTR_4, 0, "deltaTow"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_deltaTow_constraint_1, + &ASN_PER_MEMB_DELTA_TOW_CONSTR_4, 0, "deltaTow"}, {ATF_POINTER, 1, - offsetof(struct GPSTimeAssistanceMeasurements, - gpsReferenceTimeUncertainty), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GPSReferenceTimeUncertainty, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "gpsReferenceTimeUncertainty"}, + offsetof(struct GPSTimeAssistanceMeasurements, + gpsReferenceTimeUncertainty), + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GPSReferenceTimeUncertainty, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "gpsReferenceTimeUncertainty"}, }; static int asn_MAP_GPSTimeAssistanceMeasurements_oms_1[] = {1, 2, 3}; static ber_tlv_tag_t asn_DEF_GPSTimeAssistanceMeasurements_tags_1[] = { @@ -140,18 +140,18 @@ static ber_tlv_tag_t asn_DEF_GPSTimeAssistanceMeasurements_tags_1[] = { static asn_TYPE_tag2member_t asn_MAP_GPSTimeAssistanceMeasurements_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0}, /* referenceFrameMSB at 950 */ + 0}, /* referenceFrameMSB at 950 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0}, /* gpsTowSubms at 951 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0}, /* deltaTow at 952 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, - 0} /* gpsReferenceTimeUncertainty at 953 */ + 0} /* gpsReferenceTimeUncertainty at 953 */ }; static asn_SEQUENCE_specifics_t asn_SPC_GPSTimeAssistanceMeasurements_specs_1 = { sizeof(struct GPSTimeAssistanceMeasurements), offsetof(struct GPSTimeAssistanceMeasurements, _asn_ctx), asn_MAP_GPSTimeAssistanceMeasurements_tag2el_1, - 4, /* Count of tags in the map */ + 4, /* Count of tags in the map */ asn_MAP_GPSTimeAssistanceMeasurements_oms_1, /* Optional members */ 3, 0, /* Root/Additions */ @@ -174,10 +174,10 @@ asn_TYPE_descriptor_t asn_DEF_GPSTimeAssistanceMeasurements = { asn_DEF_GPSTimeAssistanceMeasurements_tags_1, sizeof(asn_DEF_GPSTimeAssistanceMeasurements_tags_1) / sizeof(asn_DEF_GPSTimeAssistanceMeasurements_tags_1[0]), /* 1 */ - asn_DEF_GPSTimeAssistanceMeasurements_tags_1, /* Same as above */ + asn_DEF_GPSTimeAssistanceMeasurements_tags_1, /* Same as above */ sizeof(asn_DEF_GPSTimeAssistanceMeasurements_tags_1) / sizeof(asn_DEF_GPSTimeAssistanceMeasurements_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GPSTimeAssistanceMeasurements_1, 4, /* Elements count */ &asn_SPC_GPSTimeAssistanceMeasurements_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GPSTimeAssistanceMeasurements.h b/src/core/libs/supl/asn-rrlp/GPSTimeAssistanceMeasurements.h index fb743aa47..e963e5f74 100644 --- a/src/core/libs/supl/asn-rrlp/GPSTimeAssistanceMeasurements.h +++ b/src/core/libs/supl/asn-rrlp/GPSTimeAssistanceMeasurements.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include #include "GPSReferenceTimeUncertainty.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/GPSWeek.c b/src/core/libs/supl/asn-rrlp/GPSWeek.c index 1eb00b295..5247934d2 100644 --- a/src/core/libs/supl/asn-rrlp/GPSWeek.c +++ b/src/core/libs/supl/asn-rrlp/GPSWeek.c @@ -7,14 +7,14 @@ #include "GPSWeek.h" int GPSWeek_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int GPSWeek_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -55,67 +55,67 @@ static void GPSWeek_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void GPSWeek_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { GPSWeek_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int GPSWeek_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { GPSWeek_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t GPSWeek_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, int tag_mode) { GPSWeek_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t GPSWeek_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { GPSWeek_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t GPSWeek_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { GPSWeek_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t GPSWeek_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { GPSWeek_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t GPSWeek_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { GPSWeek_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t GPSWeek_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { GPSWeek_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); @@ -144,7 +144,7 @@ asn_TYPE_descriptor_t asn_DEF_GPSWeek = { 0, /* Use generic outmost tag fetcher */ asn_DEF_GPSWeek_tags_1, sizeof(asn_DEF_GPSWeek_tags_1) / sizeof(asn_DEF_GPSWeek_tags_1[0]), /* 1 */ - asn_DEF_GPSWeek_tags_1, /* Same as above */ + asn_DEF_GPSWeek_tags_1, /* Same as above */ sizeof(asn_DEF_GPSWeek_tags_1) / sizeof(asn_DEF_GPSWeek_tags_1[0]), /* 1 */ &ASN_PER_TYPE_GPS_WEEK_CONSTR_1, 0, diff --git a/src/core/libs/supl/asn-rrlp/GSMTime.c b/src/core/libs/supl/asn-rrlp/GSMTime.c index 9740fa47b..8bfe718e2 100644 --- a/src/core/libs/supl/asn-rrlp/GSMTime.c +++ b/src/core/libs/supl/asn-rrlp/GSMTime.c @@ -8,32 +8,32 @@ static asn_TYPE_member_t asn_MBR_GSMTime_1[] = { {ATF_NOFLAGS, 0, offsetof(struct GSMTime, bcchCarrier), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BCCHCarrier, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "bcchCarrier"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BCCHCarrier, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "bcchCarrier"}, {ATF_NOFLAGS, 0, offsetof(struct GSMTime, bsic), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BSIC, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "bsic"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BSIC, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "bsic"}, {ATF_NOFLAGS, 0, offsetof(struct GSMTime, frameNumber), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_FrameNumber, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "frameNumber"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_FrameNumber, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "frameNumber"}, {ATF_NOFLAGS, 0, offsetof(struct GSMTime, timeSlot), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_TimeSlot, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "timeSlot"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_TimeSlot, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "timeSlot"}, {ATF_NOFLAGS, 0, offsetof(struct GSMTime, bitNumber), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BitNumber, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "bitNumber"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BitNumber, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "bitNumber"}, }; static ber_tlv_tag_t asn_DEF_GSMTime_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -70,9 +70,9 @@ asn_TYPE_descriptor_t asn_DEF_GSMTime = { 0, /* Use generic outmost tag fetcher */ asn_DEF_GSMTime_tags_1, sizeof(asn_DEF_GSMTime_tags_1) / sizeof(asn_DEF_GSMTime_tags_1[0]), /* 1 */ - asn_DEF_GSMTime_tags_1, /* Same as above */ + asn_DEF_GSMTime_tags_1, /* Same as above */ sizeof(asn_DEF_GSMTime_tags_1) / sizeof(asn_DEF_GSMTime_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GSMTime_1, 5, /* Elements count */ &asn_SPC_GSMTime_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/GSMTime.h b/src/core/libs/supl/asn-rrlp/GSMTime.h index 377c497e7..2c13c2f71 100644 --- a/src/core/libs/supl/asn-rrlp/GSMTime.h +++ b/src/core/libs/supl/asn-rrlp/GSMTime.h @@ -12,9 +12,9 @@ /* Including external dependencies */ #include "BCCHCarrier.h" #include "BSIC.h" +#include "BitNumber.h" #include "FrameNumber.h" #include "TimeSlot.h" -#include "BitNumber.h" #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/INTEGER.c b/src/core/libs/supl/asn-rrlp/INTEGER.c index 67777b094..a6ba53d1a 100644 --- a/src/core/libs/supl/asn-rrlp/INTEGER.c +++ b/src/core/libs/supl/asn-rrlp/INTEGER.c @@ -3,9 +3,9 @@ * All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ -#include #include #include /* Encoder and decoder of a primitive type */ +#include #include #include @@ -41,13 +41,13 @@ asn_TYPE_descriptor_t asn_DEF_INTEGER = { * Encode INTEGER type using DER. */ asn_enc_rval_t INTEGER_encode_der(asn_TYPE_descriptor_t *td, void *sptr, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { INTEGER_t *st = (INTEGER_t *)sptr; ASN_DEBUG("%s %s as INTEGER (tm=%d)", cb ? "Encoding" : "Estimating", - td->name, tag_mode); + td->name, tag_mode); /* * Canonicalize integer in the buffer. @@ -71,12 +71,12 @@ asn_enc_rval_t INTEGER_encode_der(asn_TYPE_descriptor_t *td, void *sptr, */ switch (*buf) { - case 0x00: - if ((buf[1] & 0x80) == 0) continue; - break; - case 0xff: - if ((buf[1] & 0x80)) continue; - break; + case 0x00: + if ((buf[1] & 0x80) == 0) continue; + break; + case 0xff: + if ((buf[1] & 0x80)) continue; + break; } break; } @@ -106,8 +106,8 @@ static const asn_INTEGER_enum_map_t *INTEGER_map_enum2value( * INTEGER specific human-readable output. */ static ssize_t INTEGER__dump(asn_TYPE_descriptor_t *td, const INTEGER_t *st, - asn_app_consume_bytes_f *cb, void *app_key, - int plainOrXER) + asn_app_consume_bytes_f *cb, void *app_key, + int plainOrXER) { asn_INTEGER_specifics_t *specs = (asn_INTEGER_specifics_t *)td->specifics; char scratch[32]; /* Enough for 64-bit integer */ @@ -129,12 +129,12 @@ static ssize_t INTEGER__dump(asn_TYPE_descriptor_t *td, const INTEGER_t *st, { switch (*buf) { - case 0x00: - if ((buf[1] & 0x80) == 0) continue; - break; - case 0xff: - if ((buf[1] & 0x80) != 0) continue; - break; + case 0x00: + if ((buf[1] & 0x80) == 0) continue; + break; + case 0xff: + if ((buf[1] & 0x80) != 0) continue; + break; } break; } @@ -163,7 +163,7 @@ static ssize_t INTEGER__dump(asn_TYPE_descriptor_t *td, const INTEGER_t *st, scr = (char *)alloca(scrsize); if (plainOrXER == 0) ret = snprintf(scr, scrsize, "%+" PRId64 "(%s)", accum, - el->enum_name); + el->enum_name); else ret = snprintf(scr, scrsize, "<%s/>", el->enum_name); } @@ -181,9 +181,9 @@ static ssize_t INTEGER__dump(asn_TYPE_descriptor_t *td, const INTEGER_t *st, scr = scratch; ret = snprintf(scr, scrsize, - (specs && specs->field_unsigned) ? "%" PRIu64 - : "%+" PRId64, - accum); + (specs && specs->field_unsigned) ? "%" PRIu64 + : "%+" PRId64, + accum); } assert(ret > 0 && (size_t)ret < scrsize); return (cb(scr, ret, app_key) < 0) ? -1 : ret; @@ -227,7 +227,7 @@ static ssize_t INTEGER__dump(asn_TYPE_descriptor_t *td, const INTEGER_t *st, * INTEGER specific human-readable output. */ int INTEGER_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { const INTEGER_t *st = (const INTEGER_t *)sptr; ssize_t ret; @@ -288,17 +288,17 @@ static const asn_INTEGER_enum_map_t *INTEGER_map_enum2value( { switch (*lp) { - case 9: - case 10: - case 11: - case 12: - case 13: - case 32: /* WSP */ - case 0x2f: /* '/' */ - case 0x3e: /* '>' */ - break; - default: - continue; + case 9: + case 10: + case 11: + case 12: + case 13: + case 32: /* WSP */ + case 0x2f: /* '/' */ + case 0x3e: /* '>' */ + break; + default: + continue; } break; } @@ -310,8 +310,8 @@ static const asn_INTEGER_enum_map_t *INTEGER_map_enum2value( key.vemap = specs->value2enum; key.evmap = specs->enum2value; el_found = (asn_INTEGER_enum_map_t *)bsearch(&key, specs->value2enum, count, - sizeof(specs->value2enum[0]), - INTEGER__compar_enum2value); + sizeof(specs->value2enum[0]), + INTEGER__compar_enum2value); if (el_found) { /* Remap enum2value into value2enum */ @@ -339,8 +339,8 @@ const asn_INTEGER_enum_map_t *INTEGER_map_value2enum( int count = specs ? specs->map_count : 0; if (!count) return 0; return (asn_INTEGER_enum_map_t *)bsearch(&value, specs->value2enum, count, - sizeof(specs->value2enum[0]), - INTEGER__compar_value2enum); + sizeof(specs->value2enum[0]), + INTEGER__compar_value2enum); } static int INTEGER_st_prealloc(INTEGER_t *st, int min_size) @@ -364,9 +364,9 @@ static int INTEGER_st_prealloc(INTEGER_t *st, int min_size) * Decode the chunk of XML text encoding INTEGER. */ static enum xer_pbd_rval INTEGER__xer_body_decode(asn_TYPE_descriptor_t *td, - void *sptr, - const void *chunk_buf, - size_t chunk_size) + void *sptr, + const void *chunk_buf, + size_t chunk_size) { INTEGER_t *st = (INTEGER_t *)sptr; int64_t sign = 1; @@ -388,7 +388,7 @@ static enum xer_pbd_rval INTEGER__xer_body_decode(asn_TYPE_descriptor_t *td, if (chunk_size) ASN_DEBUG("INTEGER body %ld 0x%2x..0x%2x", (int64_t)chunk_size, *lstart, - lstop[-1]); + lstop[-1]); /* * We may have received a tag here. It will be processed inline. @@ -399,183 +399,183 @@ static enum xer_pbd_rval INTEGER__xer_body_decode(asn_TYPE_descriptor_t *td, int lv = *lp; switch (lv) { - case 0x09: - case 0x0a: - case 0x0d: - case 0x20: - switch (state) - { - case ST_SKIPSPACE: - case ST_SKIPSPHEX: - continue; - case ST_HEXCOLON: - if (xer_is_whitespace(lp, lstop - lp)) - { - lp = lstop - 1; - continue; - } - break; - default: - break; - } - break; - case 0x2d: /* '-' */ - if (state == ST_SKIPSPACE) - { - sign = -1; - state = ST_WAITDIGITS; - continue; - } - break; - case 0x2b: /* '+' */ - if (state == ST_SKIPSPACE) - { - state = ST_WAITDIGITS; - continue; - } - break; - case 0x30: - case 0x31: - case 0x32: - case 0x33: - case 0x34: - case 0x35: - case 0x36: - case 0x37: - case 0x38: - case 0x39: - switch (state) - { - case ST_DIGITS: - break; - case ST_SKIPSPHEX: /* Fall through */ - case ST_HEXDIGIT1: - value = (lv - 0x30) << 4; - state = ST_HEXDIGIT2; - continue; - case ST_HEXDIGIT2: - value += (lv - 0x30); - state = ST_HEXCOLON; - st->buf[st->size++] = (uint8_t)value; - continue; - case ST_HEXCOLON: - return XPBD_BROKEN_ENCODING; - default: - state = ST_DIGITS; - break; - } - + case 0x09: + case 0x0a: + case 0x0d: + case 0x20: + switch (state) { - int64_t new_value = value * 10; - - if (new_value / 10 != value) /* Overflow */ - return XPBD_DECODER_LIMIT; - - value = new_value + (lv - 0x30); - /* Check for two's complement overflow */ - if (value < 0) + case ST_SKIPSPACE: + case ST_SKIPSPHEX: + continue; + case ST_HEXCOLON: + if (xer_is_whitespace(lp, lstop - lp)) { - /* Check whether it is a LONG_MIN */ - if (sign == -1 && - (uint64_t)value == ~((uint64_t)-1 >> 1)) - { - sign = 1; - } - else - { - /* Overflow */ - return XPBD_DECODER_LIMIT; - } + lp = lstop - 1; + continue; } + break; + default: + break; } - continue; - case 0x3c: /* '<' */ - if (state == ST_SKIPSPACE) + break; + case 0x2d: /* '-' */ + if (state == ST_SKIPSPACE) + { + sign = -1; + state = ST_WAITDIGITS; + continue; + } + break; + case 0x2b: /* '+' */ + if (state == ST_SKIPSPACE) + { + state = ST_WAITDIGITS; + continue; + } + break; + case 0x30: + case 0x31: + case 0x32: + case 0x33: + case 0x34: + case 0x35: + case 0x36: + case 0x37: + case 0x38: + case 0x39: + switch (state) + { + case ST_DIGITS: + break; + case ST_SKIPSPHEX: /* Fall through */ + case ST_HEXDIGIT1: + value = (lv - 0x30) << 4; + state = ST_HEXDIGIT2; + continue; + case ST_HEXDIGIT2: + value += (lv - 0x30); + state = ST_HEXCOLON; + st->buf[st->size++] = (uint8_t)value; + continue; + case ST_HEXCOLON: + return XPBD_BROKEN_ENCODING; + default: + state = ST_DIGITS; + break; + } + + { + int64_t new_value = value * 10; + + if (new_value / 10 != value) /* Overflow */ + return XPBD_DECODER_LIMIT; + + value = new_value + (lv - 0x30); + /* Check for two's complement overflow */ + if (value < 0) { - const asn_INTEGER_enum_map_t *el; - el = INTEGER_map_enum2value( - (asn_INTEGER_specifics_t *)td->specifics, - lstart, lstop); - if (el) + /* Check whether it is a LONG_MIN */ + if (sign == -1 && + (uint64_t)value == ~((uint64_t)-1 >> 1)) { - ASN_DEBUG("Found \"%s\" => %ld", - el->enum_name, el->nat_value); - state = ST_DIGITS; - value = el->nat_value; - lp = lstop - 1; - continue; + sign = 1; + } + else + { + /* Overflow */ + return XPBD_DECODER_LIMIT; } - ASN_DEBUG("Unknown identifier for INTEGER"); } - return XPBD_BROKEN_ENCODING; - case 0x3a: /* ':' */ - if (state == ST_HEXCOLON) - { - /* This colon is expected */ - state = ST_HEXDIGIT1; - continue; - } - else if (state == ST_DIGITS) - { - /* The colon here means that we have + } + continue; + case 0x3c: /* '<' */ + if (state == ST_SKIPSPACE) + { + const asn_INTEGER_enum_map_t *el; + el = INTEGER_map_enum2value( + (asn_INTEGER_specifics_t *)td->specifics, + lstart, lstop); + if (el) + { + ASN_DEBUG("Found \"%s\" => %ld", + el->enum_name, el->nat_value); + state = ST_DIGITS; + value = el->nat_value; + lp = lstop - 1; + continue; + } + ASN_DEBUG("Unknown identifier for INTEGER"); + } + return XPBD_BROKEN_ENCODING; + case 0x3a: /* ':' */ + if (state == ST_HEXCOLON) + { + /* This colon is expected */ + state = ST_HEXDIGIT1; + continue; + } + else if (state == ST_DIGITS) + { + /* The colon here means that we have * decoded the first two hexadecimal * places as a decimal value. * Switch decoding mode. */ - ASN_DEBUG("INTEGER re-evaluate as hex form"); - if (INTEGER_st_prealloc(st, - (chunk_size / 3) + 1)) - return XPBD_SYSTEM_FAILURE; - state = ST_SKIPSPHEX; - lp = lstart - 1; - continue; - } - else - { - ASN_DEBUG("state %d at %d", state, lp - lstart); - break; - } - /* [A-Fa-f] */ - case 0x41: - case 0x42: - case 0x43: - case 0x44: - case 0x45: - case 0x46: - case 0x61: - case 0x62: - case 0x63: - case 0x64: - case 0x65: - case 0x66: - switch (state) - { - case ST_SKIPSPHEX: - case ST_SKIPSPACE: /* Fall through */ - case ST_HEXDIGIT1: - value = lv - ((lv < 0x61) ? 0x41 : 0x61); - value += 10; - value <<= 4; - state = ST_HEXDIGIT2; - continue; - case ST_HEXDIGIT2: - value += lv - ((lv < 0x61) ? 0x41 : 0x61); - value += 10; - st->buf[st->size++] = (uint8_t)value; - state = ST_HEXCOLON; - continue; - case ST_DIGITS: - ASN_DEBUG( - "INTEGER re-evaluate as hex form"); - if (INTEGER_st_prealloc( - st, (chunk_size / 3) + 1)) - return XPBD_SYSTEM_FAILURE; - state = ST_SKIPSPHEX; - lp = lstart - 1; - continue; - default: - break; - } - break; + ASN_DEBUG("INTEGER re-evaluate as hex form"); + if (INTEGER_st_prealloc(st, + (chunk_size / 3) + 1)) + return XPBD_SYSTEM_FAILURE; + state = ST_SKIPSPHEX; + lp = lstart - 1; + continue; + } + else + { + ASN_DEBUG("state %d at %d", state, lp - lstart); + break; + } + /* [A-Fa-f] */ + case 0x41: + case 0x42: + case 0x43: + case 0x44: + case 0x45: + case 0x46: + case 0x61: + case 0x62: + case 0x63: + case 0x64: + case 0x65: + case 0x66: + switch (state) + { + case ST_SKIPSPHEX: + case ST_SKIPSPACE: /* Fall through */ + case ST_HEXDIGIT1: + value = lv - ((lv < 0x61) ? 0x41 : 0x61); + value += 10; + value <<= 4; + state = ST_HEXDIGIT2; + continue; + case ST_HEXDIGIT2: + value += lv - ((lv < 0x61) ? 0x41 : 0x61); + value += 10; + st->buf[st->size++] = (uint8_t)value; + state = ST_HEXCOLON; + continue; + case ST_DIGITS: + ASN_DEBUG( + "INTEGER re-evaluate as hex form"); + if (INTEGER_st_prealloc( + st, (chunk_size / 3) + 1)) + return XPBD_SYSTEM_FAILURE; + state = ST_SKIPSPHEX; + lp = lstart - 1; + continue; + default: + break; + } + break; } /* Found extra non-numeric stuff */ @@ -586,29 +586,29 @@ static enum xer_pbd_rval INTEGER__xer_body_decode(asn_TYPE_descriptor_t *td, switch (state) { - case ST_DIGITS: - /* Everything is cool */ - break; - case ST_HEXCOLON: - st->buf[st->size] = 0; /* Just in case termination */ - return XPBD_BODY_CONSUMED; - case ST_HEXDIGIT1: - case ST_HEXDIGIT2: - case ST_SKIPSPHEX: - return XPBD_BROKEN_ENCODING; - default: - if (xer_is_whitespace(lp, lstop - lp)) - { - if (state != ST_EXTRASTUFF) return XPBD_NOT_BODY_IGNORE; - break; - } - else - { - ASN_DEBUG("INTEGER: No useful digits (state %d)", - state); - return XPBD_BROKEN_ENCODING; /* No digits */ - } - break; + case ST_DIGITS: + /* Everything is cool */ + break; + case ST_HEXCOLON: + st->buf[st->size] = 0; /* Just in case termination */ + return XPBD_BODY_CONSUMED; + case ST_HEXDIGIT1: + case ST_HEXDIGIT2: + case ST_SKIPSPHEX: + return XPBD_BROKEN_ENCODING; + default: + if (xer_is_whitespace(lp, lstop - lp)) + { + if (state != ST_EXTRASTUFF) return XPBD_NOT_BODY_IGNORE; + break; + } + else + { + ASN_DEBUG("INTEGER: No useful digits (state %d)", + state); + return XPBD_BROKEN_ENCODING; /* No digits */ + } + break; } value *= sign; /* Change sign, if needed */ @@ -619,18 +619,18 @@ static enum xer_pbd_rval INTEGER__xer_body_decode(asn_TYPE_descriptor_t *td, } asn_dec_rval_t INTEGER_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **sptr, - const char *opt_mname, const void *buf_ptr, - size_t size) + asn_TYPE_descriptor_t *td, void **sptr, + const char *opt_mname, const void *buf_ptr, + size_t size) { return xer_decode_primitive(opt_codec_ctx, td, sptr, sizeof(INTEGER_t), - opt_mname, buf_ptr, size, - INTEGER__xer_body_decode); + opt_mname, buf_ptr, size, + INTEGER__xer_body_decode); } asn_enc_rval_t INTEGER_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { const INTEGER_t *st = (const INTEGER_t *)sptr; asn_enc_rval_t er; @@ -647,9 +647,9 @@ asn_enc_rval_t INTEGER_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, } asn_dec_rval_t INTEGER_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd) { asn_INTEGER_specifics_t *specs = (asn_INTEGER_specifics_t *)td->specifics; asn_dec_rval_t rval = {RC_OK, 0}; @@ -718,7 +718,7 @@ asn_dec_rval_t INTEGER_decode_uper(asn_codec_ctx_t *opt_codec_ctx, if (value < 0) _ASN_DECODE_STARVED; } ASN_DEBUG("Got value %ld + low %ld", value, - ct->lower_bound); + ct->lower_bound); value += ct->lower_bound; if ((specs && specs->field_unsigned) ? asn_ulong2INTEGER(st, value) @@ -770,8 +770,8 @@ asn_dec_rval_t INTEGER_decode_uper(asn_codec_ctx_t *opt_codec_ctx, } asn_enc_rval_t INTEGER_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *sptr, asn_per_outp_t *po) + asn_per_constraints_t *constraints, + void *sptr, asn_per_outp_t *po) { asn_INTEGER_specifics_t *specs = (asn_INTEGER_specifics_t *)td->specifics; asn_enc_rval_t er; @@ -807,8 +807,8 @@ asn_enc_rval_t INTEGER_encode_uper(asn_TYPE_descriptor_t *td, inext = 1; } ASN_DEBUG("Value %lu (%02x/%d) lb %lu ub %lu %s", uval, - st->buf[0], st->size, ct->lower_bound, - ct->upper_bound, inext ? "ext" : "fix"); + st->buf[0], st->size, ct->lower_bound, + ct->upper_bound, inext ? "ext" : "fix"); value = uval; } else @@ -826,8 +826,8 @@ asn_enc_rval_t INTEGER_encode_uper(asn_TYPE_descriptor_t *td, inext = 1; } ASN_DEBUG("Value %ld (%02x/%d) lb %ld ub %ld %s", value, - st->buf[0], st->size, ct->lower_bound, - ct->upper_bound, inext ? "ext" : "fix"); + st->buf[0], st->size, ct->lower_bound, + ct->upper_bound, inext ? "ext" : "fix"); } if (ct->flags & APC_EXTENSIBLE) { @@ -856,7 +856,7 @@ asn_enc_rval_t INTEGER_encode_uper(asn_TYPE_descriptor_t *td, else { if (per_put_few_bits(po, value - ct->lower_bound, - ct->range_bits)) + ct->range_bits)) _ASN_ENCODE_FAILED; } _ASN_ENCODED_OK(er); @@ -913,12 +913,12 @@ int asn_INTEGER2long(const INTEGER_t *iptr, int64_t *lptr) { switch (*b) { - case 0x00: - if ((b[1] & 0x80) == 0) continue; - break; - case 0xff: - if ((b[1] & 0x80) != 0) continue; - break; + case 0x00: + if ((b[1] & 0x80) == 0) continue; + break; + case 0xff: + if ((b[1] & 0x80) != 0) continue; + break; } break; } @@ -1054,12 +1054,12 @@ int asn_long2INTEGER(INTEGER_t *st, int64_t value) { switch (*p) { - case 0x00: - if ((*(p + add) & 0x80) == 0) continue; - break; - case 0xff: - if ((*(p + add) & 0x80)) continue; - break; + case 0x00: + if ((*(p + add) & 0x80) == 0) continue; + break; + case 0xff: + if ((*(p + add) & 0x80)) continue; + break; } break; } diff --git a/src/core/libs/supl/asn-rrlp/IonosphericModel.c b/src/core/libs/supl/asn-rrlp/IonosphericModel.c index 3ed4b9d73..044d84cff 100644 --- a/src/core/libs/supl/asn-rrlp/IonosphericModel.c +++ b/src/core/libs/supl/asn-rrlp/IonosphericModel.c @@ -7,15 +7,15 @@ #include "IonosphericModel.h" static int memb_alfa0_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,21 +29,21 @@ static int memb_alfa0_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_alfa1_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -57,21 +57,21 @@ static int memb_alfa1_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_alfa2_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -85,21 +85,21 @@ static int memb_alfa2_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_alfa3_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -113,21 +113,21 @@ static int memb_alfa3_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_beta0_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -141,21 +141,21 @@ static int memb_beta0_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_beta1_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -169,21 +169,21 @@ static int memb_beta1_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_beta2_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -197,21 +197,21 @@ static int memb_beta2_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_beta3_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -225,7 +225,7 @@ static int memb_beta3_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -280,37 +280,37 @@ static asn_per_constraints_t ASN_PER_MEMB_BETA3_CONSTR_9 = { }; static asn_TYPE_member_t asn_MBR_IonosphericModel_1[] = { {ATF_NOFLAGS, 0, offsetof(struct IonosphericModel, alfa0), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_alfa0_constraint_1, - &ASN_PER_MEMB_ALFA0_CONSTR_2, 0, "alfa0"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_alfa0_constraint_1, + &ASN_PER_MEMB_ALFA0_CONSTR_2, 0, "alfa0"}, {ATF_NOFLAGS, 0, offsetof(struct IonosphericModel, alfa1), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_alfa1_constraint_1, - &ASN_PER_MEMB_ALFA1_CONSTR_3, 0, "alfa1"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_alfa1_constraint_1, + &ASN_PER_MEMB_ALFA1_CONSTR_3, 0, "alfa1"}, {ATF_NOFLAGS, 0, offsetof(struct IonosphericModel, alfa2), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_alfa2_constraint_1, - &ASN_PER_MEMB_ALFA2_CONSTR_4, 0, "alfa2"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_alfa2_constraint_1, + &ASN_PER_MEMB_ALFA2_CONSTR_4, 0, "alfa2"}, {ATF_NOFLAGS, 0, offsetof(struct IonosphericModel, alfa3), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_alfa3_constraint_1, - &ASN_PER_MEMB_ALFA3_CONSTR_5, 0, "alfa3"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_alfa3_constraint_1, + &ASN_PER_MEMB_ALFA3_CONSTR_5, 0, "alfa3"}, {ATF_NOFLAGS, 0, offsetof(struct IonosphericModel, beta0), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_beta0_constraint_1, - &ASN_PER_MEMB_BETA0_CONSTR_6, 0, "beta0"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_beta0_constraint_1, + &ASN_PER_MEMB_BETA0_CONSTR_6, 0, "beta0"}, {ATF_NOFLAGS, 0, offsetof(struct IonosphericModel, beta1), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_beta1_constraint_1, - &ASN_PER_MEMB_BETA1_CONSTR_7, 0, "beta1"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_beta1_constraint_1, + &ASN_PER_MEMB_BETA1_CONSTR_7, 0, "beta1"}, {ATF_NOFLAGS, 0, offsetof(struct IonosphericModel, beta2), - (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_beta2_constraint_1, - &ASN_PER_MEMB_BETA2_CONSTR_8, 0, "beta2"}, + (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_beta2_constraint_1, + &ASN_PER_MEMB_BETA2_CONSTR_8, 0, "beta2"}, {ATF_NOFLAGS, 0, offsetof(struct IonosphericModel, beta3), - (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_beta3_constraint_1, - &ASN_PER_MEMB_BETA3_CONSTR_9, 0, "beta3"}, + (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_beta3_constraint_1, + &ASN_PER_MEMB_BETA3_CONSTR_9, 0, "beta3"}, }; static ber_tlv_tag_t asn_DEF_IonosphericModel_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -354,7 +354,7 @@ asn_TYPE_descriptor_t asn_DEF_IonosphericModel = { asn_DEF_IonosphericModel_tags_1, /* Same as above */ sizeof(asn_DEF_IonosphericModel_tags_1) / sizeof(asn_DEF_IonosphericModel_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_IonosphericModel_1, 8, /* Elements count */ &asn_SPC_IonosphericModel_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/LAC.c b/src/core/libs/supl/asn-rrlp/LAC.c index 8529f4f78..c72a1d4ce 100644 --- a/src/core/libs/supl/asn-rrlp/LAC.c +++ b/src/core/libs/supl/asn-rrlp/LAC.c @@ -7,14 +7,14 @@ #include "LAC.h" int LAC_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int LAC_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -61,60 +61,60 @@ void LAC_free(asn_TYPE_descriptor_t *td, void *struct_ptr, int contents_only) } int LAC_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { LAC_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t LAC_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, int tag_mode) { LAC_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t LAC_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { LAC_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t LAC_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { LAC_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t LAC_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { LAC_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t LAC_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { LAC_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t LAC_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { LAC_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); @@ -143,7 +143,7 @@ asn_TYPE_descriptor_t asn_DEF_LAC = { 0, /* Use generic outmost tag fetcher */ asn_DEF_LAC_tags_1, sizeof(asn_DEF_LAC_tags_1) / sizeof(asn_DEF_LAC_tags_1[0]), /* 1 */ - asn_DEF_LAC_tags_1, /* Same as above */ + asn_DEF_LAC_tags_1, /* Same as above */ sizeof(asn_DEF_LAC_tags_1) / sizeof(asn_DEF_LAC_tags_1[0]), /* 1 */ &ASN_PER_TYPE_LAC_CONSTR_1, 0, diff --git a/src/core/libs/supl/asn-rrlp/LocErrorReason.c b/src/core/libs/supl/asn-rrlp/LocErrorReason.c index 9d09337ad..88a257184 100644 --- a/src/core/libs/supl/asn-rrlp/LocErrorReason.c +++ b/src/core/libs/supl/asn-rrlp/LocErrorReason.c @@ -7,8 +7,8 @@ #include "LocErrorReason.h" int LocErrorReason_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { /* Replace with underlying type checker */ td->check_constraints = asn_DEF_ENUMERATED.check_constraints; @@ -39,75 +39,75 @@ static void LocErrorReason_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void LocErrorReason_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { LocErrorReason_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int LocErrorReason_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { LocErrorReason_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t LocErrorReason_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { LocErrorReason_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t LocErrorReason_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { LocErrorReason_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t LocErrorReason_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { LocErrorReason_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t LocErrorReason_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { LocErrorReason_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t LocErrorReason_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { LocErrorReason_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t LocErrorReason_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { LocErrorReason_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/LocationError.c b/src/core/libs/supl/asn-rrlp/LocationError.c index 5b5df88cb..faf6a60bd 100644 --- a/src/core/libs/supl/asn-rrlp/LocationError.c +++ b/src/core/libs/supl/asn-rrlp/LocationError.c @@ -8,17 +8,17 @@ static asn_TYPE_member_t asn_MBR_LocationError_1[] = { {ATF_NOFLAGS, 0, offsetof(struct LocationError, locErrorReason), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_LocErrorReason, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "locErrorReason"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_LocErrorReason, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "locErrorReason"}, {ATF_POINTER, 1, offsetof(struct LocationError, additionalAssistanceData), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_AdditionalAssistanceData, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "additionalAssistanceData"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_AdditionalAssistanceData, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "additionalAssistanceData"}, }; static int asn_MAP_LocationError_oms_1[] = {1}; static ber_tlv_tag_t asn_DEF_LocationError_tags_1[] = { @@ -26,7 +26,7 @@ static ber_tlv_tag_t asn_DEF_LocationError_tags_1[] = { static asn_TYPE_tag2member_t asn_MAP_LocationError_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* locErrorReason at 488 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0} /* additionalAssistanceData at 489 */ + 0} /* additionalAssistanceData at 489 */ }; static asn_SEQUENCE_specifics_t asn_SPC_LocationError_specs_1 = { sizeof(struct LocationError), @@ -58,7 +58,7 @@ asn_TYPE_descriptor_t asn_DEF_LocationError = { asn_DEF_LocationError_tags_1, /* Same as above */ sizeof(asn_DEF_LocationError_tags_1) / sizeof(asn_DEF_LocationError_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_LocationError_1, 2, /* Elements count */ &asn_SPC_LocationError_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/LocationInfo.c b/src/core/libs/supl/asn-rrlp/LocationInfo.c index c2c75df51..0e3652170 100644 --- a/src/core/libs/supl/asn-rrlp/LocationInfo.c +++ b/src/core/libs/supl/asn-rrlp/LocationInfo.c @@ -7,16 +7,16 @@ #include "LocationInfo.h" static int memb_refFrame_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,21 +30,21 @@ static int memb_refFrame_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_gpsTOW_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -58,7 +58,7 @@ static int memb_gpsTOW_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -77,24 +77,24 @@ static asn_per_constraints_t ASN_PER_MEMB_GPS_TOW_CONSTR_3 = { }; static asn_TYPE_member_t asn_MBR_LocationInfo_1[] = { {ATF_NOFLAGS, 0, offsetof(struct LocationInfo, refFrame), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_refFrame_constraint_1, - &ASN_PER_MEMB_REF_FRAME_CONSTR_2, 0, "refFrame"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_refFrame_constraint_1, + &ASN_PER_MEMB_REF_FRAME_CONSTR_2, 0, "refFrame"}, {ATF_POINTER, 1, offsetof(struct LocationInfo, gpsTOW), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_gpsTOW_constraint_1, - &ASN_PER_MEMB_GPS_TOW_CONSTR_3, 0, "gpsTOW"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_gpsTOW_constraint_1, + &ASN_PER_MEMB_GPS_TOW_CONSTR_3, 0, "gpsTOW"}, {ATF_NOFLAGS, 0, offsetof(struct LocationInfo, fixType), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_FixType, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "fixType"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_FixType, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "fixType"}, {ATF_NOFLAGS, 0, offsetof(struct LocationInfo, posEstimate), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Ext_GeographicalInformation, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "posEstimate"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Ext_GeographicalInformation, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "posEstimate"}, }; static int asn_MAP_LocationInfo_oms_1[] = {1}; static ber_tlv_tag_t asn_DEF_LocationInfo_tags_1[] = { diff --git a/src/core/libs/supl/asn-rrlp/LocationInfo.h b/src/core/libs/supl/asn-rrlp/LocationInfo.h index 1d6ffa117..7b6110490 100644 --- a/src/core/libs/supl/asn-rrlp/LocationInfo.h +++ b/src/core/libs/supl/asn-rrlp/LocationInfo.h @@ -10,9 +10,9 @@ #include /* Including external dependencies */ -#include -#include "FixType.h" #include "Ext-GeographicalInformation.h" +#include "FixType.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/MeasureResponseTime.c b/src/core/libs/supl/asn-rrlp/MeasureResponseTime.c index 33393464b..1baaf7db4 100644 --- a/src/core/libs/supl/asn-rrlp/MeasureResponseTime.c +++ b/src/core/libs/supl/asn-rrlp/MeasureResponseTime.c @@ -7,15 +7,15 @@ #include "MeasureResponseTime.h" int MeasureResponseTime_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ int MeasureResponseTime_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -57,57 +57,57 @@ static void MeasureResponseTime_1_inherit_TYPE_descriptor( } void MeasureResponseTime_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { MeasureResponseTime_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int MeasureResponseTime_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, + void *app_key) { MeasureResponseTime_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t MeasureResponseTime_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, + const void *bufptr, size_t size, + int tag_mode) { MeasureResponseTime_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t MeasureResponseTime_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { MeasureResponseTime_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t MeasureResponseTime_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { MeasureResponseTime_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t MeasureResponseTime_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { MeasureResponseTime_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); @@ -120,7 +120,7 @@ asn_dec_rval_t MeasureResponseTime_decode_uper( { MeasureResponseTime_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t MeasureResponseTime_encode_uper( diff --git a/src/core/libs/supl/asn-rrlp/MethodType.c b/src/core/libs/supl/asn-rrlp/MethodType.c index 02c8a8191..fef90a4fd 100644 --- a/src/core/libs/supl/asn-rrlp/MethodType.c +++ b/src/core/libs/supl/asn-rrlp/MethodType.c @@ -14,26 +14,26 @@ static asn_per_constraints_t ASN_PER_TYPE_METHOD_TYPE_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_MethodType_1[] = { {ATF_NOFLAGS, 0, offsetof(struct MethodType, choice.msAssisted), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_AccuracyOpt, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "msAssisted"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_AccuracyOpt, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "msAssisted"}, {ATF_NOFLAGS, 0, offsetof(struct MethodType, choice.msBased), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Accuracy, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "msBased"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Accuracy, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "msBased"}, {ATF_NOFLAGS, 0, offsetof(struct MethodType, choice.msBasedPref), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Accuracy, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "msBasedPref"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Accuracy, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "msBasedPref"}, {ATF_NOFLAGS, 0, offsetof(struct MethodType, choice.msAssistedPref), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Accuracy, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "msAssistedPref"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Accuracy, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "msAssistedPref"}, }; static asn_TYPE_tag2member_t asn_MAP_MethodType_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* msAssisted at 117 */ diff --git a/src/core/libs/supl/asn-rrlp/MethodType.h b/src/core/libs/supl/asn-rrlp/MethodType.h index b99be62ca..93a63b158 100644 --- a/src/core/libs/supl/asn-rrlp/MethodType.h +++ b/src/core/libs/supl/asn-rrlp/MethodType.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include "AccuracyOpt.h" #include "Accuracy.h" +#include "AccuracyOpt.h" #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/ModuloTimeSlot.c b/src/core/libs/supl/asn-rrlp/ModuloTimeSlot.c index a2f5092cf..feab85dd1 100644 --- a/src/core/libs/supl/asn-rrlp/ModuloTimeSlot.c +++ b/src/core/libs/supl/asn-rrlp/ModuloTimeSlot.c @@ -7,15 +7,15 @@ #include "ModuloTimeSlot.h" int ModuloTimeSlot_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ int ModuloTimeSlot_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -56,75 +56,75 @@ static void ModuloTimeSlot_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void ModuloTimeSlot_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { ModuloTimeSlot_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int ModuloTimeSlot_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { ModuloTimeSlot_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t ModuloTimeSlot_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { ModuloTimeSlot_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t ModuloTimeSlot_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { ModuloTimeSlot_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t ModuloTimeSlot_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { ModuloTimeSlot_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t ModuloTimeSlot_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { ModuloTimeSlot_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t ModuloTimeSlot_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { ModuloTimeSlot_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t ModuloTimeSlot_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { ModuloTimeSlot_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/MoreAssDataToBeSent.c b/src/core/libs/supl/asn-rrlp/MoreAssDataToBeSent.c index 83ac43ebb..30b1235c3 100644 --- a/src/core/libs/supl/asn-rrlp/MoreAssDataToBeSent.c +++ b/src/core/libs/supl/asn-rrlp/MoreAssDataToBeSent.c @@ -7,8 +7,8 @@ #include "MoreAssDataToBeSent.h" int MoreAssDataToBeSent_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { /* Replace with underlying type checker */ td->check_constraints = asn_DEF_ENUMERATED.check_constraints; @@ -40,57 +40,57 @@ static void MoreAssDataToBeSent_1_inherit_TYPE_descriptor( } void MoreAssDataToBeSent_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { MoreAssDataToBeSent_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int MoreAssDataToBeSent_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, + void *app_key) { MoreAssDataToBeSent_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t MoreAssDataToBeSent_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, + const void *bufptr, size_t size, + int tag_mode) { MoreAssDataToBeSent_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t MoreAssDataToBeSent_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { MoreAssDataToBeSent_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t MoreAssDataToBeSent_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { MoreAssDataToBeSent_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t MoreAssDataToBeSent_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { MoreAssDataToBeSent_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); @@ -103,7 +103,7 @@ asn_dec_rval_t MoreAssDataToBeSent_decode_uper( { MoreAssDataToBeSent_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t MoreAssDataToBeSent_encode_uper( @@ -129,10 +129,10 @@ static unsigned int asn_MAP_MoreAssDataToBeSent_enum2value_1[] = { static asn_INTEGER_specifics_t asn_SPC_MoreAssDataToBeSent_specs_1 = { asn_MAP_MoreAssDataToBeSent_value2enum_1, /* "tag" => N; sorted by tag */ asn_MAP_MoreAssDataToBeSent_enum2value_1, /* N => "tag"; sorted by N */ - 2, /* Number of elements in the maps */ - 0, /* Enumeration is not extensible */ - 1, /* Strict enumeration */ - 0, /* Native long size */ + 2, /* Number of elements in the maps */ + 0, /* Enumeration is not extensible */ + 1, /* Strict enumeration */ + 0, /* Native long size */ 0}; static ber_tlv_tag_t asn_DEF_MoreAssDataToBeSent_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (10 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/MpathIndic.c b/src/core/libs/supl/asn-rrlp/MpathIndic.c index 9cf71b2a0..73119ea00 100644 --- a/src/core/libs/supl/asn-rrlp/MpathIndic.c +++ b/src/core/libs/supl/asn-rrlp/MpathIndic.c @@ -7,7 +7,7 @@ #include "MpathIndic.h" int MpathIndic_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { /* Replace with underlying type checker */ td->check_constraints = asn_DEF_ENUMERATED.check_constraints; @@ -38,69 +38,69 @@ static void MpathIndic_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void MpathIndic_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { MpathIndic_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int MpathIndic_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { MpathIndic_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t MpathIndic_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { MpathIndic_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t MpathIndic_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { MpathIndic_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t MpathIndic_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, const char *opt_mname, + const void *bufptr, size_t size) { MpathIndic_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t MpathIndic_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { MpathIndic_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t MpathIndic_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { MpathIndic_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t MpathIndic_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { MpathIndic_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/MsrAssistBTS-R98-ExpOTD.c b/src/core/libs/supl/asn-rrlp/MsrAssistBTS-R98-ExpOTD.c index 6aa864b8c..42b21312c 100644 --- a/src/core/libs/supl/asn-rrlp/MsrAssistBTS-R98-ExpOTD.c +++ b/src/core/libs/supl/asn-rrlp/MsrAssistBTS-R98-ExpOTD.c @@ -8,24 +8,24 @@ static asn_TYPE_member_t asn_MBR_MsrAssistBTS_R98_ExpOTD_1[] = { {ATF_NOFLAGS, 0, offsetof(struct MsrAssistBTS_R98_ExpOTD, expectedOTD), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_ExpectedOTD, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "expectedOTD"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_ExpectedOTD, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "expectedOTD"}, {ATF_NOFLAGS, 0, - offsetof(struct MsrAssistBTS_R98_ExpOTD, expOTDUncertainty), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_ExpOTDUncertainty, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "expOTDUncertainty"}, + offsetof(struct MsrAssistBTS_R98_ExpOTD, expOTDUncertainty), + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_ExpOTDUncertainty, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "expOTDUncertainty"}, }; static ber_tlv_tag_t asn_DEF_MsrAssistBTS_R98_ExpOTD_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_MsrAssistBTS_R98_ExpOTD_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* expectedOTD at 910 */ - {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0} /* expOTDUncertainty at 912 */ + {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0} /* expOTDUncertainty at 912 */ }; static asn_SEQUENCE_specifics_t asn_SPC_MsrAssistBTS_R98_ExpOTD_specs_1 = { sizeof(struct MsrAssistBTS_R98_ExpOTD), @@ -57,7 +57,7 @@ asn_TYPE_descriptor_t asn_DEF_MsrAssistBTS_R98_ExpOTD = { asn_DEF_MsrAssistBTS_R98_ExpOTD_tags_1, /* Same as above */ sizeof(asn_DEF_MsrAssistBTS_R98_ExpOTD_tags_1) / sizeof(asn_DEF_MsrAssistBTS_R98_ExpOTD_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_MsrAssistBTS_R98_ExpOTD_1, 2, /* Elements count */ &asn_SPC_MsrAssistBTS_R98_ExpOTD_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/MsrAssistBTS-R98-ExpOTD.h b/src/core/libs/supl/asn-rrlp/MsrAssistBTS-R98-ExpOTD.h index 63a4ae3c6..eb7665078 100644 --- a/src/core/libs/supl/asn-rrlp/MsrAssistBTS-R98-ExpOTD.h +++ b/src/core/libs/supl/asn-rrlp/MsrAssistBTS-R98-ExpOTD.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include "ExpectedOTD.h" #include "ExpOTDUncertainty.h" +#include "ExpectedOTD.h" #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/MsrAssistBTS.c b/src/core/libs/supl/asn-rrlp/MsrAssistBTS.c index 81bc52b82..6ecd40727 100644 --- a/src/core/libs/supl/asn-rrlp/MsrAssistBTS.c +++ b/src/core/libs/supl/asn-rrlp/MsrAssistBTS.c @@ -8,39 +8,39 @@ static asn_TYPE_member_t asn_MBR_MsrAssistBTS_1[] = { {ATF_NOFLAGS, 0, offsetof(struct MsrAssistBTS, bcchCarrier), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BCCHCarrier, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "bcchCarrier"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BCCHCarrier, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "bcchCarrier"}, {ATF_NOFLAGS, 0, offsetof(struct MsrAssistBTS, bsic), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BSIC, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "bsic"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BSIC, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "bsic"}, {ATF_NOFLAGS, 0, offsetof(struct MsrAssistBTS, multiFrameOffset), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_MultiFrameOffset, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "multiFrameOffset"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_MultiFrameOffset, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "multiFrameOffset"}, {ATF_NOFLAGS, 0, offsetof(struct MsrAssistBTS, timeSlotScheme), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_TimeSlotScheme, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "timeSlotScheme"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_TimeSlotScheme, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "timeSlotScheme"}, {ATF_NOFLAGS, 0, offsetof(struct MsrAssistBTS, roughRTD), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_RoughRTD, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "roughRTD"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_RoughRTD, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "roughRTD"}, {ATF_POINTER, 1, offsetof(struct MsrAssistBTS, calcAssistanceBTS), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_CalcAssistanceBTS, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "calcAssistanceBTS"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_CalcAssistanceBTS, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "calcAssistanceBTS"}, }; static int asn_MAP_MsrAssistBTS_oms_1[] = {5}; static ber_tlv_tag_t asn_DEF_MsrAssistBTS_tags_1[] = { @@ -51,7 +51,7 @@ static asn_TYPE_tag2member_t asn_MAP_MsrAssistBTS_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0}, /* multiFrameOffset at 195 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, 0}, /* timeSlotScheme at 196 */ {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, 0}, /* roughRTD at 197 */ - {(ASN_TAG_CLASS_CONTEXT | (5 << 2)), 5, 0, 0} /* calcAssistanceBTS at 200 */ + {(ASN_TAG_CLASS_CONTEXT | (5 << 2)), 5, 0, 0} /* calcAssistanceBTS at 200 */ }; static asn_SEQUENCE_specifics_t asn_SPC_MsrAssistBTS_specs_1 = { sizeof(struct MsrAssistBTS), diff --git a/src/core/libs/supl/asn-rrlp/MsrAssistBTS.h b/src/core/libs/supl/asn-rrlp/MsrAssistBTS.h index f39c569b7..9a261bf76 100644 --- a/src/core/libs/supl/asn-rrlp/MsrAssistBTS.h +++ b/src/core/libs/supl/asn-rrlp/MsrAssistBTS.h @@ -13,8 +13,8 @@ #include "BCCHCarrier.h" #include "BSIC.h" #include "MultiFrameOffset.h" -#include "TimeSlotScheme.h" #include "RoughRTD.h" +#include "TimeSlotScheme.h" #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/MsrAssistData-R98-ExpOTD.c b/src/core/libs/supl/asn-rrlp/MsrAssistData-R98-ExpOTD.c index b353b894c..a910bdb9e 100644 --- a/src/core/libs/supl/asn-rrlp/MsrAssistData-R98-ExpOTD.c +++ b/src/core/libs/supl/asn-rrlp/MsrAssistData-R98-ExpOTD.c @@ -8,18 +8,18 @@ static asn_TYPE_member_t asn_MBR_MsrAssistData_R98_ExpOTD_1[] = { {ATF_NOFLAGS, 0, - offsetof(struct MsrAssistData_R98_ExpOTD, msrAssistList_R98_ExpOTD), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfMsrAssistBTS_R98_ExpOTD, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "msrAssistList-R98-ExpOTD"}, + offsetof(struct MsrAssistData_R98_ExpOTD, msrAssistList_R98_ExpOTD), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfMsrAssistBTS_R98_ExpOTD, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "msrAssistList-R98-ExpOTD"}, }; static ber_tlv_tag_t asn_DEF_MsrAssistData_R98_ExpOTD_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_MsrAssistData_R98_ExpOTD_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0} /* msrAssistList-R98-ExpOTD at 900 */ + 0} /* msrAssistList-R98-ExpOTD at 900 */ }; static asn_SEQUENCE_specifics_t asn_SPC_MsrAssistData_R98_ExpOTD_specs_1 = { sizeof(struct MsrAssistData_R98_ExpOTD), @@ -51,7 +51,7 @@ asn_TYPE_descriptor_t asn_DEF_MsrAssistData_R98_ExpOTD = { asn_DEF_MsrAssistData_R98_ExpOTD_tags_1, /* Same as above */ sizeof(asn_DEF_MsrAssistData_R98_ExpOTD_tags_1) / sizeof(asn_DEF_MsrAssistData_R98_ExpOTD_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_MsrAssistData_R98_ExpOTD_1, 1, /* Elements count */ &asn_SPC_MsrAssistData_R98_ExpOTD_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/MsrAssistData.c b/src/core/libs/supl/asn-rrlp/MsrAssistData.c index 83c463998..7d61c2a8f 100644 --- a/src/core/libs/supl/asn-rrlp/MsrAssistData.c +++ b/src/core/libs/supl/asn-rrlp/MsrAssistData.c @@ -8,11 +8,11 @@ static asn_TYPE_member_t asn_MBR_MsrAssistData_1[] = { {ATF_NOFLAGS, 0, offsetof(struct MsrAssistData, msrAssistList), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfMsrAssistBTS, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "msrAssistList"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfMsrAssistBTS, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "msrAssistList"}, }; static ber_tlv_tag_t asn_DEF_MsrAssistData_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -49,7 +49,7 @@ asn_TYPE_descriptor_t asn_DEF_MsrAssistData = { asn_DEF_MsrAssistData_tags_1, /* Same as above */ sizeof(asn_DEF_MsrAssistData_tags_1) / sizeof(asn_DEF_MsrAssistData_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_MsrAssistData_1, 1, /* Elements count */ &asn_SPC_MsrAssistData_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/MsrPosition-Req.c b/src/core/libs/supl/asn-rrlp/MsrPosition-Req.c index 2a3a0941a..dd988d698 100644 --- a/src/core/libs/supl/asn-rrlp/MsrPosition-Req.c +++ b/src/core/libs/supl/asn-rrlp/MsrPosition-Req.c @@ -8,55 +8,55 @@ static asn_TYPE_member_t asn_MBR_MsrPosition_Req_1[] = { {ATF_NOFLAGS, 0, offsetof(struct MsrPosition_Req, positionInstruct), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_PositionInstruct, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "positionInstruct"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_PositionInstruct, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "positionInstruct"}, {ATF_POINTER, 7, offsetof(struct MsrPosition_Req, referenceAssistData), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_ReferenceAssistData, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "referenceAssistData"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_ReferenceAssistData, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "referenceAssistData"}, {ATF_POINTER, 6, offsetof(struct MsrPosition_Req, msrAssistData), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_MsrAssistData, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "msrAssistData"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_MsrAssistData, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "msrAssistData"}, {ATF_POINTER, 5, offsetof(struct MsrPosition_Req, systemInfoAssistData), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SystemInfoAssistData, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "systemInfoAssistData"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SystemInfoAssistData, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "systemInfoAssistData"}, {ATF_POINTER, 4, offsetof(struct MsrPosition_Req, gps_AssistData), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GPS_AssistData, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "gps-AssistData"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GPS_AssistData, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "gps-AssistData"}, {ATF_POINTER, 3, offsetof(struct MsrPosition_Req, extensionContainer), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_ExtensionContainer, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "extensionContainer"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_ExtensionContainer, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "extensionContainer"}, {ATF_POINTER, 2, - offsetof(struct MsrPosition_Req, rel98_MsrPosition_Req_extension), - (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Rel98_MsrPosition_Req_Extension, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "rel98-MsrPosition-Req-extension"}, + offsetof(struct MsrPosition_Req, rel98_MsrPosition_Req_extension), + (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Rel98_MsrPosition_Req_Extension, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "rel98-MsrPosition-Req-extension"}, {ATF_POINTER, 1, - offsetof(struct MsrPosition_Req, rel5_MsrPosition_Req_extension), - (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Rel5_MsrPosition_Req_Extension, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "rel5-MsrPosition-Req-extension"}, + offsetof(struct MsrPosition_Req, rel5_MsrPosition_Req_extension), + (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Rel5_MsrPosition_Req_Extension, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "rel5-MsrPosition-Req-extension"}, }; static int asn_MAP_MsrPosition_Req_oms_1[] = {1, 2, 3, 4, 5, 6, 7}; static ber_tlv_tag_t asn_DEF_MsrPosition_Req_tags_1[] = { @@ -64,17 +64,17 @@ static ber_tlv_tag_t asn_DEF_MsrPosition_Req_tags_1[] = { static asn_TYPE_tag2member_t asn_MAP_MsrPosition_Req_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* positionInstruct at 31 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0}, /* referenceAssistData at 32 */ + 0}, /* referenceAssistData at 32 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0}, /* msrAssistData at 33 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, - 0}, /* systemInfoAssistData at 34 */ + 0}, /* systemInfoAssistData at 34 */ {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, 0}, /* gps-AssistData at 35 */ {(ASN_TAG_CLASS_CONTEXT | (5 << 2)), 5, 0, - 0}, /* extensionContainer at 36 */ + 0}, /* extensionContainer at 36 */ {(ASN_TAG_CLASS_CONTEXT | (6 << 2)), 6, 0, - 0}, /* rel98-MsrPosition-Req-extension at 39 */ + 0}, /* rel98-MsrPosition-Req-extension at 39 */ {(ASN_TAG_CLASS_CONTEXT | (7 << 2)), 7, 0, - 0} /* rel5-MsrPosition-Req-extension at 41 */ + 0} /* rel5-MsrPosition-Req-extension at 41 */ }; static asn_SEQUENCE_specifics_t asn_SPC_MsrPosition_Req_specs_1 = { sizeof(struct MsrPosition_Req), @@ -106,7 +106,7 @@ asn_TYPE_descriptor_t asn_DEF_MsrPosition_Req = { asn_DEF_MsrPosition_Req_tags_1, /* Same as above */ sizeof(asn_DEF_MsrPosition_Req_tags_1) / sizeof(asn_DEF_MsrPosition_Req_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_MsrPosition_Req_1, 8, /* Elements count */ &asn_SPC_MsrPosition_Req_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/MsrPosition-Req.h b/src/core/libs/supl/asn-rrlp/MsrPosition-Req.h index 80548b197..dc236aa28 100644 --- a/src/core/libs/supl/asn-rrlp/MsrPosition-Req.h +++ b/src/core/libs/supl/asn-rrlp/MsrPosition-Req.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include "PositionInstruct.h" #include "ExtensionContainer.h" +#include "PositionInstruct.h" #include #ifdef __cplusplus @@ -57,12 +57,12 @@ extern "C" #endif /* Referred external types */ -#include "ReferenceAssistData.h" -#include "MsrAssistData.h" -#include "SystemInfoAssistData.h" #include "GPS-AssistData.h" -#include "Rel98-MsrPosition-Req-Extension.h" +#include "MsrAssistData.h" +#include "ReferenceAssistData.h" #include "Rel5-MsrPosition-Req-Extension.h" +#include "Rel98-MsrPosition-Req-Extension.h" +#include "SystemInfoAssistData.h" #endif /* _MsrPosition_Req_H_ */ #include diff --git a/src/core/libs/supl/asn-rrlp/MsrPosition-Rsp.c b/src/core/libs/supl/asn-rrlp/MsrPosition-Rsp.c index 9a095c7da..f7a24d31e 100644 --- a/src/core/libs/supl/asn-rrlp/MsrPosition-Rsp.c +++ b/src/core/libs/supl/asn-rrlp/MsrPosition-Rsp.c @@ -8,61 +8,61 @@ static asn_TYPE_member_t asn_MBR_MsrPosition_Rsp_1[] = { {ATF_POINTER, 9, offsetof(struct MsrPosition_Rsp, multipleSets), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_MultipleSets, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "multipleSets"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_MultipleSets, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "multipleSets"}, {ATF_POINTER, 8, offsetof(struct MsrPosition_Rsp, referenceIdentity), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_ReferenceIdentity, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "referenceIdentity"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_ReferenceIdentity, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "referenceIdentity"}, {ATF_POINTER, 7, offsetof(struct MsrPosition_Rsp, otd_MeasureInfo), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_OTD_MeasureInfo, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "otd-MeasureInfo"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_OTD_MeasureInfo, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "otd-MeasureInfo"}, {ATF_POINTER, 6, offsetof(struct MsrPosition_Rsp, locationInfo), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_LocationInfo, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "locationInfo"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_LocationInfo, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "locationInfo"}, {ATF_POINTER, 5, offsetof(struct MsrPosition_Rsp, gps_MeasureInfo), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GPS_MeasureInfo, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "gps-MeasureInfo"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GPS_MeasureInfo, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "gps-MeasureInfo"}, {ATF_POINTER, 4, offsetof(struct MsrPosition_Rsp, locationError), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_LocationError, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "locationError"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_LocationError, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "locationError"}, {ATF_POINTER, 3, offsetof(struct MsrPosition_Rsp, extensionContainer), - (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_ExtensionContainer, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "extensionContainer"}, + (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_ExtensionContainer, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "extensionContainer"}, {ATF_POINTER, 2, - offsetof(struct MsrPosition_Rsp, rel_98_MsrPosition_Rsp_Extension), - (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Rel_98_MsrPosition_Rsp_Extension, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "rel-98-MsrPosition-Rsp-Extension"}, + offsetof(struct MsrPosition_Rsp, rel_98_MsrPosition_Rsp_Extension), + (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Rel_98_MsrPosition_Rsp_Extension, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "rel-98-MsrPosition-Rsp-Extension"}, {ATF_POINTER, 1, - offsetof(struct MsrPosition_Rsp, rel_5_MsrPosition_Rsp_Extension), - (ASN_TAG_CLASS_CONTEXT | (8 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Rel_5_MsrPosition_Rsp_Extension, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "rel-5-MsrPosition-Rsp-Extension"}, + offsetof(struct MsrPosition_Rsp, rel_5_MsrPosition_Rsp_Extension), + (ASN_TAG_CLASS_CONTEXT | (8 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Rel_5_MsrPosition_Rsp_Extension, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "rel-5-MsrPosition-Rsp-Extension"}, }; static int asn_MAP_MsrPosition_Rsp_oms_1[] = {0, 1, 2, 3, 4, 5, 6, 7, 8}; static ber_tlv_tag_t asn_DEF_MsrPosition_Rsp_tags_1[] = { @@ -75,11 +75,11 @@ static asn_TYPE_tag2member_t asn_MAP_MsrPosition_Rsp_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, 0}, /* gps-MeasureInfo at 55 */ {(ASN_TAG_CLASS_CONTEXT | (5 << 2)), 5, 0, 0}, /* locationError at 56 */ {(ASN_TAG_CLASS_CONTEXT | (6 << 2)), 6, 0, - 0}, /* extensionContainer at 57 */ + 0}, /* extensionContainer at 57 */ {(ASN_TAG_CLASS_CONTEXT | (7 << 2)), 7, 0, - 0}, /* rel-98-MsrPosition-Rsp-Extension at 61 */ + 0}, /* rel-98-MsrPosition-Rsp-Extension at 61 */ {(ASN_TAG_CLASS_CONTEXT | (8 << 2)), 8, 0, - 0} /* rel-5-MsrPosition-Rsp-Extension at 63 */ + 0} /* rel-5-MsrPosition-Rsp-Extension at 63 */ }; static asn_SEQUENCE_specifics_t asn_SPC_MsrPosition_Rsp_specs_1 = { sizeof(struct MsrPosition_Rsp), @@ -111,7 +111,7 @@ asn_TYPE_descriptor_t asn_DEF_MsrPosition_Rsp = { asn_DEF_MsrPosition_Rsp_tags_1, /* Same as above */ sizeof(asn_DEF_MsrPosition_Rsp_tags_1) / sizeof(asn_DEF_MsrPosition_Rsp_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_MsrPosition_Rsp_1, 9, /* Elements count */ &asn_SPC_MsrPosition_Rsp_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/MsrPosition-Rsp.h b/src/core/libs/supl/asn-rrlp/MsrPosition-Rsp.h index d3aee5c32..1ca039415 100644 --- a/src/core/libs/supl/asn-rrlp/MsrPosition-Rsp.h +++ b/src/core/libs/supl/asn-rrlp/MsrPosition-Rsp.h @@ -59,14 +59,14 @@ extern "C" #endif /* Referred external types */ -#include "MultipleSets.h" -#include "ReferenceIdentity.h" -#include "OTD-MeasureInfo.h" -#include "LocationInfo.h" #include "GPS-MeasureInfo.h" #include "LocationError.h" -#include "Rel-98-MsrPosition-Rsp-Extension.h" +#include "LocationInfo.h" +#include "MultipleSets.h" +#include "OTD-MeasureInfo.h" +#include "ReferenceIdentity.h" #include "Rel-5-MsrPosition-Rsp-Extension.h" +#include "Rel-98-MsrPosition-Rsp-Extension.h" #endif /* _MsrPosition_Rsp_H_ */ #include diff --git a/src/core/libs/supl/asn-rrlp/MultiFrameCarrier.c b/src/core/libs/supl/asn-rrlp/MultiFrameCarrier.c index c76dfa37c..9948ad421 100644 --- a/src/core/libs/supl/asn-rrlp/MultiFrameCarrier.c +++ b/src/core/libs/supl/asn-rrlp/MultiFrameCarrier.c @@ -8,17 +8,17 @@ static asn_TYPE_member_t asn_MBR_MultiFrameCarrier_1[] = { {ATF_NOFLAGS, 0, offsetof(struct MultiFrameCarrier, bcchCarrier), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BCCHCarrier, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "bcchCarrier"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BCCHCarrier, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "bcchCarrier"}, {ATF_NOFLAGS, 0, offsetof(struct MultiFrameCarrier, multiFrameOffset), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_MultiFrameOffset, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "multiFrameOffset"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_MultiFrameOffset, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "multiFrameOffset"}, }; static ber_tlv_tag_t asn_DEF_MultiFrameCarrier_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -56,7 +56,7 @@ asn_TYPE_descriptor_t asn_DEF_MultiFrameCarrier = { asn_DEF_MultiFrameCarrier_tags_1, /* Same as above */ sizeof(asn_DEF_MultiFrameCarrier_tags_1) / sizeof(asn_DEF_MultiFrameCarrier_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_MultiFrameCarrier_1, 2, /* Elements count */ &asn_SPC_MultiFrameCarrier_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/MultiFrameOffset.c b/src/core/libs/supl/asn-rrlp/MultiFrameOffset.c index 292097309..27c8d0362 100644 --- a/src/core/libs/supl/asn-rrlp/MultiFrameOffset.c +++ b/src/core/libs/supl/asn-rrlp/MultiFrameOffset.c @@ -7,15 +7,15 @@ #include "MultiFrameOffset.h" int MultiFrameOffset_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ int MultiFrameOffset_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -57,76 +57,76 @@ static void MultiFrameOffset_1_inherit_TYPE_descriptor( } void MultiFrameOffset_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { MultiFrameOffset_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int MultiFrameOffset_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, + void *app_key) { MultiFrameOffset_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t MultiFrameOffset_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { MultiFrameOffset_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t MultiFrameOffset_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { MultiFrameOffset_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t MultiFrameOffset_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { MultiFrameOffset_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t MultiFrameOffset_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { MultiFrameOffset_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t MultiFrameOffset_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { MultiFrameOffset_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t MultiFrameOffset_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { MultiFrameOffset_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/MultipleSets.c b/src/core/libs/supl/asn-rrlp/MultipleSets.c index 26bf60c18..2a4658e18 100644 --- a/src/core/libs/supl/asn-rrlp/MultipleSets.c +++ b/src/core/libs/supl/asn-rrlp/MultipleSets.c @@ -7,16 +7,16 @@ #include "MultipleSets.h" static int memb_nbrOfSets_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,7 +30,7 @@ static int memb_nbrOfSets_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -44,7 +44,7 @@ static int memb_nbrOfReferenceBTSs_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -58,7 +58,7 @@ static int memb_nbrOfReferenceBTSs_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -77,19 +77,19 @@ static asn_per_constraints_t ASN_PER_MEMB_NBR_OF_REFERENCE_BT_SS_CONSTR_3 = { }; static asn_TYPE_member_t asn_MBR_MultipleSets_1[] = { {ATF_NOFLAGS, 0, offsetof(struct MultipleSets, nbrOfSets), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_nbrOfSets_constraint_1, - &ASN_PER_MEMB_NBR_OF_SETS_CONSTR_2, 0, "nbrOfSets"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_nbrOfSets_constraint_1, + &ASN_PER_MEMB_NBR_OF_SETS_CONSTR_2, 0, "nbrOfSets"}, {ATF_NOFLAGS, 0, offsetof(struct MultipleSets, nbrOfReferenceBTSs), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_nbrOfReferenceBTSs_constraint_1, - &ASN_PER_MEMB_NBR_OF_REFERENCE_BT_SS_CONSTR_3, 0, "nbrOfReferenceBTSs"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_nbrOfReferenceBTSs_constraint_1, + &ASN_PER_MEMB_NBR_OF_REFERENCE_BT_SS_CONSTR_3, 0, "nbrOfReferenceBTSs"}, {ATF_POINTER, 1, offsetof(struct MultipleSets, referenceRelation), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_ReferenceRelation, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "referenceRelation"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_ReferenceRelation, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "referenceRelation"}, }; static int asn_MAP_MultipleSets_oms_1[] = {2}; static ber_tlv_tag_t asn_DEF_MultipleSets_tags_1[] = { @@ -97,7 +97,7 @@ static ber_tlv_tag_t asn_DEF_MultipleSets_tags_1[] = { static asn_TYPE_tag2member_t asn_MAP_MultipleSets_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* nbrOfSets at 267 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0}, /* nbrOfReferenceBTSs at 270 */ + 0}, /* nbrOfReferenceBTSs at 270 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0} /* referenceRelation at 274 */ }; static asn_SEQUENCE_specifics_t asn_SPC_MultipleSets_specs_1 = { diff --git a/src/core/libs/supl/asn-rrlp/MultipleSets.h b/src/core/libs/supl/asn-rrlp/MultipleSets.h index daa565302..893a19d0a 100644 --- a/src/core/libs/supl/asn-rrlp/MultipleSets.h +++ b/src/core/libs/supl/asn-rrlp/MultipleSets.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include #include "ReferenceRelation.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/NULL.c b/src/core/libs/supl/asn-rrlp/NULL.c index c6950577d..6842d0e8f 100644 --- a/src/core/libs/supl/asn-rrlp/NULL.c +++ b/src/core/libs/supl/asn-rrlp/NULL.c @@ -2,10 +2,10 @@ * Copyright (c) 2003, 2005 Lev Walkin . All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ -#include -#include -#include #include /* Implemented in terms of BOOLEAN type */ +#include +#include +#include /* * NULL basic type description. @@ -36,8 +36,8 @@ asn_TYPE_descriptor_t asn_DEF_NULL = { }; asn_enc_rval_t NULL_encode_der(asn_TYPE_descriptor_t *td, void *ptr, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { asn_enc_rval_t erval; @@ -52,8 +52,8 @@ asn_enc_rval_t NULL_encode_der(asn_TYPE_descriptor_t *td, void *ptr, } asn_enc_rval_t NULL_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { asn_enc_rval_t er; @@ -70,9 +70,9 @@ asn_enc_rval_t NULL_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, } static enum xer_pbd_rval NULL__xer_body_decode(asn_TYPE_descriptor_t *td, - void *sptr, - const void *chunk_buf, - size_t chunk_size) + void *sptr, + const void *chunk_buf, + size_t chunk_size) { (void)td; (void)sptr; @@ -84,17 +84,17 @@ static enum xer_pbd_rval NULL__xer_body_decode(asn_TYPE_descriptor_t *td, } asn_dec_rval_t NULL_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **sptr, - const char *opt_mname, const void *buf_ptr, - size_t size) + asn_TYPE_descriptor_t *td, void **sptr, + const char *opt_mname, const void *buf_ptr, + size_t size) { return xer_decode_primitive(opt_codec_ctx, td, sptr, sizeof(NULL_t), - opt_mname, buf_ptr, size, - NULL__xer_body_decode); + opt_mname, buf_ptr, size, + NULL__xer_body_decode); } int NULL_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { (void)td; /* Unused argument */ (void)ilevel; /* Unused argument */ @@ -110,9 +110,9 @@ int NULL_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, } asn_dec_rval_t NULL_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, void **sptr, - asn_per_data_t *pd) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, void **sptr, + asn_per_data_t *pd) { asn_dec_rval_t rv; @@ -144,8 +144,8 @@ asn_dec_rval_t NULL_decode_uper(asn_codec_ctx_t *opt_codec_ctx, } asn_enc_rval_t NULL_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, void *sptr, - asn_per_outp_t *po) + asn_per_constraints_t *constraints, void *sptr, + asn_per_outp_t *po) { asn_enc_rval_t er; diff --git a/src/core/libs/supl/asn-rrlp/NativeEnumerated.c b/src/core/libs/supl/asn-rrlp/NativeEnumerated.c index dd4d3f235..1f6394e52 100644 --- a/src/core/libs/supl/asn-rrlp/NativeEnumerated.c +++ b/src/core/libs/supl/asn-rrlp/NativeEnumerated.c @@ -9,8 +9,8 @@ * implementation deals with the standard (machine-specific) representation * of them instead of using the platform-independent buffer. */ -#include #include +#include /* * NativeEnumerated basic type description. @@ -43,10 +43,10 @@ asn_TYPE_descriptor_t asn_DEF_NativeEnumerated = { }; asn_enc_rval_t NativeEnumerated_encode_xer(asn_TYPE_descriptor_t *td, - void *sptr, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *sptr, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { asn_INTEGER_specifics_t *specs = (asn_INTEGER_specifics_t *)td->specifics; asn_enc_rval_t er; @@ -79,9 +79,9 @@ asn_enc_rval_t NativeEnumerated_encode_xer(asn_TYPE_descriptor_t *td, } asn_dec_rval_t NativeEnumerated_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd) { asn_INTEGER_specifics_t *specs = (asn_INTEGER_specifics_t *)td->specifics; asn_dec_rval_t rval = {RC_OK, 0}; @@ -150,8 +150,8 @@ static int NativeEnumerated__compar_value2enum(const void *ap, const void *bp) } asn_enc_rval_t NativeEnumerated_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *sptr, asn_per_outp_t *po) + asn_per_constraints_t *constraints, + void *sptr, asn_per_outp_t *po) { asn_INTEGER_specifics_t *specs = (asn_INTEGER_specifics_t *)td->specifics; asn_enc_rval_t er; @@ -181,7 +181,7 @@ asn_enc_rval_t NativeEnumerated_encode_uper(asn_TYPE_descriptor_t *td, key.nat_value = native; kf = bsearch(&key, specs->value2enum, specs->map_count, sizeof(key), - NativeEnumerated__compar_value2enum); + NativeEnumerated__compar_value2enum); if (!kf) { ASN_DEBUG("No element corresponds to %ld", native); @@ -217,8 +217,8 @@ asn_enc_rval_t NativeEnumerated_encode_uper(asn_TYPE_descriptor_t *td, * X.691, #10.6: normally small non-negative whole number; */ ASN_DEBUG("value = %ld, ext = %d, inext = %d, res = %ld", value, - specs->extension, inext, - value - (inext ? (specs->extension - 1) : 0)); + specs->extension, inext, + value - (inext ? (specs->extension - 1) : 0)); if (uper_put_nsnnwn(po, value - (inext ? (specs->extension - 1) : 0))) _ASN_ENCODE_FAILED; diff --git a/src/core/libs/supl/asn-rrlp/NativeInteger.c b/src/core/libs/supl/asn-rrlp/NativeInteger.c index 4439da598..53895a7bb 100644 --- a/src/core/libs/supl/asn-rrlp/NativeInteger.c +++ b/src/core/libs/supl/asn-rrlp/NativeInteger.c @@ -10,8 +10,8 @@ * implementation deals with the standard (machine-specific) representation * of them instead of using the platform-independent buffer. */ -#include #include +#include /* * NativeInteger basic type description. @@ -45,9 +45,9 @@ asn_TYPE_descriptor_t asn_DEF_NativeInteger = { * Decode INTEGER type. */ asn_dec_rval_t NativeInteger_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **nint_ptr, const void *buf_ptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **nint_ptr, const void *buf_ptr, + size_t size, int tag_mode) { asn_INTEGER_specifics_t *specs = (asn_INTEGER_specifics_t *)td->specifics; long *native = (long *)*nint_ptr; @@ -74,7 +74,7 @@ asn_dec_rval_t NativeInteger_decode_ber(asn_codec_ctx_t *opt_codec_ctx, * Check tags. */ rval = ber_check_tags(opt_codec_ctx, td, 0, buf_ptr, size, tag_mode, 0, - &length, 0); + &length, 0); if (rval.code != RC_OK) return rval; ASN_DEBUG("%s length is %d bytes", td->name, (int)length); @@ -125,7 +125,7 @@ asn_dec_rval_t NativeInteger_decode_ber(asn_codec_ctx_t *opt_codec_ctx, rval.consumed += length; ASN_DEBUG("Took %ld/%ld bytes to encode %s (%ld)", (long)rval.consumed, - (long)length, td->name, *native); + (long)length, td->name, *native); return rval; } @@ -134,9 +134,9 @@ asn_dec_rval_t NativeInteger_decode_ber(asn_codec_ctx_t *opt_codec_ctx, * Encode the NativeInteger using the standard INTEGER type DER encoder. */ asn_enc_rval_t NativeInteger_encode_der(asn_TYPE_descriptor_t *sd, void *ptr, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { uint64_t native = *(uint64_t *)ptr; /* Disable sign ext. */ asn_enc_rval_t erval; @@ -173,9 +173,9 @@ asn_enc_rval_t NativeInteger_encode_der(asn_TYPE_descriptor_t *sd, void *ptr, * Decode the chunk of XML text encoding INTEGER. */ asn_dec_rval_t NativeInteger_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **sptr, - const char *opt_mname, - const void *buf_ptr, size_t size) + asn_TYPE_descriptor_t *td, void **sptr, + const char *opt_mname, + const void *buf_ptr, size_t size) { asn_INTEGER_specifics_t *specs = (asn_INTEGER_specifics_t *)td->specifics; asn_dec_rval_t rval; @@ -191,7 +191,7 @@ asn_dec_rval_t NativeInteger_decode_xer(asn_codec_ctx_t *opt_codec_ctx, memset(&st, 0, sizeof(st)); rval = INTEGER_decode_xer(opt_codec_ctx, td, &st_ptr, opt_mname, buf_ptr, - size); + size); if (rval.code == RC_OK) { int64_t l; @@ -221,10 +221,10 @@ asn_dec_rval_t NativeInteger_decode_xer(asn_codec_ctx_t *opt_codec_ctx, } asn_enc_rval_t NativeInteger_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, - int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { asn_INTEGER_specifics_t *specs = (asn_INTEGER_specifics_t *)td->specifics; char scratch[32]; /* Enough for 64-bit int */ @@ -238,7 +238,7 @@ asn_enc_rval_t NativeInteger_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, er.encoded = snprintf(scratch, sizeof(scratch), - (specs && specs->field_unsigned) ? "%lu" : "%ld", *native); + (specs && specs->field_unsigned) ? "%lu" : "%ld", *native); if (er.encoded <= 0 || (size_t)er.encoded >= sizeof(scratch) || cb(scratch, er.encoded, app_key) < 0) _ASN_ENCODE_FAILED; @@ -247,9 +247,9 @@ asn_enc_rval_t NativeInteger_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, } asn_dec_rval_t NativeInteger_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd) { asn_INTEGER_specifics_t *specs = (asn_INTEGER_specifics_t *)td->specifics; asn_dec_rval_t rval; @@ -283,8 +283,8 @@ asn_dec_rval_t NativeInteger_decode_uper(asn_codec_ctx_t *opt_codec_ctx, } asn_enc_rval_t NativeInteger_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *sptr, asn_per_outp_t *po) + asn_per_constraints_t *constraints, + void *sptr, asn_per_outp_t *po) { asn_INTEGER_specifics_t *specs = (asn_INTEGER_specifics_t *)td->specifics; asn_enc_rval_t er; @@ -310,7 +310,7 @@ asn_enc_rval_t NativeInteger_encode_uper(asn_TYPE_descriptor_t *td, * INTEGER specific human-readable output. */ int NativeInteger_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { asn_INTEGER_specifics_t *specs = (asn_INTEGER_specifics_t *)td->specifics; const long *native = (const long *)sptr; @@ -323,8 +323,8 @@ int NativeInteger_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, if (native) { ret = snprintf(scratch, sizeof(scratch), - (specs && specs->field_unsigned) ? "%lu" : "%ld", - *native); + (specs && specs->field_unsigned) ? "%lu" : "%ld", + *native); assert(ret > 0 && (size_t)ret < sizeof(scratch)); return (cb(scratch, ret, app_key) < 0) ? -1 : 0; } @@ -339,7 +339,7 @@ void NativeInteger_free(asn_TYPE_descriptor_t *td, void *ptr, int contents_only) if (!td || !ptr) return; ASN_DEBUG("Freeing %s as INTEGER (%d, %p, Native)", td->name, contents_only, - ptr); + ptr); if (!contents_only) { diff --git a/src/core/libs/supl/asn-rrlp/NativeInteger.h b/src/core/libs/supl/asn-rrlp/NativeInteger.h index 14311ae57..0fe9afff4 100644 --- a/src/core/libs/supl/asn-rrlp/NativeInteger.h +++ b/src/core/libs/supl/asn-rrlp/NativeInteger.h @@ -12,8 +12,8 @@ #ifndef _NativeInteger_H_ #define _NativeInteger_H_ -#include #include +#include #ifdef __cplusplus extern "C" diff --git a/src/core/libs/supl/asn-rrlp/NavModel-KeplerianSet.c b/src/core/libs/supl/asn-rrlp/NavModel-KeplerianSet.c index 5f729c464..db882e79a 100644 --- a/src/core/libs/supl/asn-rrlp/NavModel-KeplerianSet.c +++ b/src/core/libs/supl/asn-rrlp/NavModel-KeplerianSet.c @@ -7,16 +7,16 @@ #include "NavModel-KeplerianSet.h" static int memb_keplerToeLSB_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,22 +30,22 @@ static int memb_keplerToeLSB_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_keplerW_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -59,22 +59,22 @@ static int memb_keplerW_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_keplerDeltaN_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -88,22 +88,22 @@ static int memb_keplerDeltaN_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_keplerM0_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -117,7 +117,7 @@ static int memb_keplerM0_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -131,7 +131,7 @@ static int memb_keplerOmegaDot_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -145,22 +145,22 @@ static int memb_keplerOmegaDot_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_keplerELSB_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -174,22 +174,22 @@ static int memb_keplerELSB_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_keplerIDot_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -203,7 +203,7 @@ static int memb_keplerIDot_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -217,7 +217,7 @@ static int memb_keplerAPowerHalfLSB_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -231,22 +231,22 @@ static int memb_keplerAPowerHalfLSB_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_keplerI0_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -260,22 +260,22 @@ static int memb_keplerI0_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_keplerOmega0_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -289,22 +289,22 @@ static int memb_keplerOmega0_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_keplerCrs_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -318,22 +318,22 @@ static int memb_keplerCrs_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_keplerCis_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -347,22 +347,22 @@ static int memb_keplerCis_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_keplerCus_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -376,22 +376,22 @@ static int memb_keplerCus_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_keplerCrc_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -405,22 +405,22 @@ static int memb_keplerCrc_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_keplerCic_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -434,22 +434,22 @@ static int memb_keplerCic_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_keplerCuc_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -463,7 +463,7 @@ static int memb_keplerCuc_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -476,7 +476,7 @@ static asn_per_constraints_t ASN_PER_MEMB_KEPLER_TOE_LSB_CONSTR_2 = { }; static asn_per_constraints_t ASN_PER_MEMB_KEPLER_W_CONSTR_3 = { {APC_CONSTRAINED, 32, -1, (-2147483647L - 1), - 2147483647} /* (-2147483648..2147483647) */, + 2147483647} /* (-2147483648..2147483647) */, {APC_UNCONSTRAINED, -1, -1, 0, 0}, 0, 0 /* No PER value map */ @@ -489,7 +489,7 @@ static asn_per_constraints_t ASN_PER_MEMB_KEPLER_DELTA_N_CONSTR_4 = { }; static asn_per_constraints_t ASN_PER_MEMB_KEPLER_M0_CONSTR_5 = { {APC_CONSTRAINED, 32, -1, (-2147483647L - 1), - 2147483647} /* (-2147483648..2147483647) */, + 2147483647} /* (-2147483648..2147483647) */, {APC_UNCONSTRAINED, -1, -1, 0, 0}, 0, 0 /* No PER value map */ @@ -520,14 +520,14 @@ static asn_per_constraints_t ASN_PER_MEMB_KEPLER_A_POWER_HALF_LSB_CONSTR_9 = { }; static asn_per_constraints_t ASN_PER_MEMB_KEPLER_I0_CONSTR_10 = { {APC_CONSTRAINED, 32, -1, (-2147483647L - 1), - 2147483647} /* (-2147483648..2147483647) */, + 2147483647} /* (-2147483648..2147483647) */, {APC_UNCONSTRAINED, -1, -1, 0, 0}, 0, 0 /* No PER value map */ }; static asn_per_constraints_t ASN_PER_MEMB_KEPLER_OMEGA0_CONSTR_11 = { {APC_CONSTRAINED, 32, -1, (-2147483647L - 1), - 2147483647} /* (-2147483648..2147483647) */, + 2147483647} /* (-2147483648..2147483647) */, {APC_UNCONSTRAINED, -1, -1, 0, 0}, 0, 0 /* No PER value map */ @@ -570,76 +570,76 @@ static asn_per_constraints_t ASN_PER_MEMB_KEPLER_CUC_CONSTR_17 = { }; static asn_TYPE_member_t asn_MBR_NavModel_KeplerianSet_1[] = { {ATF_NOFLAGS, 0, offsetof(struct NavModel_KeplerianSet, keplerToeLSB), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_keplerToeLSB_constraint_1, - &ASN_PER_MEMB_KEPLER_TOE_LSB_CONSTR_2, 0, "keplerToeLSB"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_keplerToeLSB_constraint_1, + &ASN_PER_MEMB_KEPLER_TOE_LSB_CONSTR_2, 0, "keplerToeLSB"}, {ATF_NOFLAGS, 0, offsetof(struct NavModel_KeplerianSet, keplerW), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_keplerW_constraint_1, - &ASN_PER_MEMB_KEPLER_W_CONSTR_3, 0, "keplerW"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_keplerW_constraint_1, + &ASN_PER_MEMB_KEPLER_W_CONSTR_3, 0, "keplerW"}, {ATF_NOFLAGS, 0, offsetof(struct NavModel_KeplerianSet, keplerDeltaN), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_keplerDeltaN_constraint_1, - &ASN_PER_MEMB_KEPLER_DELTA_N_CONSTR_4, 0, "keplerDeltaN"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_keplerDeltaN_constraint_1, + &ASN_PER_MEMB_KEPLER_DELTA_N_CONSTR_4, 0, "keplerDeltaN"}, {ATF_NOFLAGS, 0, offsetof(struct NavModel_KeplerianSet, keplerM0), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_keplerM0_constraint_1, - &ASN_PER_MEMB_KEPLER_M0_CONSTR_5, 0, "keplerM0"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_keplerM0_constraint_1, + &ASN_PER_MEMB_KEPLER_M0_CONSTR_5, 0, "keplerM0"}, {ATF_NOFLAGS, 0, offsetof(struct NavModel_KeplerianSet, keplerOmegaDot), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_keplerOmegaDot_constraint_1, - &ASN_PER_MEMB_KEPLER_OMEGA_DOT_CONSTR_6, 0, "keplerOmegaDot"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_keplerOmegaDot_constraint_1, + &ASN_PER_MEMB_KEPLER_OMEGA_DOT_CONSTR_6, 0, "keplerOmegaDot"}, {ATF_NOFLAGS, 0, offsetof(struct NavModel_KeplerianSet, keplerELSB), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_keplerELSB_constraint_1, - &ASN_PER_MEMB_KEPLER_ELSB_CONSTR_7, 0, "keplerELSB"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_keplerELSB_constraint_1, + &ASN_PER_MEMB_KEPLER_ELSB_CONSTR_7, 0, "keplerELSB"}, {ATF_NOFLAGS, 0, offsetof(struct NavModel_KeplerianSet, keplerIDot), - (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_keplerIDot_constraint_1, - &ASN_PER_MEMB_KEPLER_I_DOT_CONSTR_8, 0, "keplerIDot"}, + (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_keplerIDot_constraint_1, + &ASN_PER_MEMB_KEPLER_I_DOT_CONSTR_8, 0, "keplerIDot"}, {ATF_NOFLAGS, 0, - offsetof(struct NavModel_KeplerianSet, keplerAPowerHalfLSB), - (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_keplerAPowerHalfLSB_constraint_1, - &ASN_PER_MEMB_KEPLER_A_POWER_HALF_LSB_CONSTR_9, 0, "keplerAPowerHalfLSB"}, + offsetof(struct NavModel_KeplerianSet, keplerAPowerHalfLSB), + (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_keplerAPowerHalfLSB_constraint_1, + &ASN_PER_MEMB_KEPLER_A_POWER_HALF_LSB_CONSTR_9, 0, "keplerAPowerHalfLSB"}, {ATF_NOFLAGS, 0, offsetof(struct NavModel_KeplerianSet, keplerI0), - (ASN_TAG_CLASS_CONTEXT | (8 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_keplerI0_constraint_1, - &ASN_PER_MEMB_KEPLER_I0_CONSTR_10, 0, "keplerI0"}, + (ASN_TAG_CLASS_CONTEXT | (8 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_keplerI0_constraint_1, + &ASN_PER_MEMB_KEPLER_I0_CONSTR_10, 0, "keplerI0"}, {ATF_NOFLAGS, 0, offsetof(struct NavModel_KeplerianSet, keplerOmega0), - (ASN_TAG_CLASS_CONTEXT | (9 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_keplerOmega0_constraint_1, - &ASN_PER_MEMB_KEPLER_OMEGA0_CONSTR_11, 0, "keplerOmega0"}, + (ASN_TAG_CLASS_CONTEXT | (9 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_keplerOmega0_constraint_1, + &ASN_PER_MEMB_KEPLER_OMEGA0_CONSTR_11, 0, "keplerOmega0"}, {ATF_NOFLAGS, 0, offsetof(struct NavModel_KeplerianSet, keplerCrs), - (ASN_TAG_CLASS_CONTEXT | (10 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_keplerCrs_constraint_1, - &ASN_PER_MEMB_KEPLER_CRS_CONSTR_12, 0, "keplerCrs"}, + (ASN_TAG_CLASS_CONTEXT | (10 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_keplerCrs_constraint_1, + &ASN_PER_MEMB_KEPLER_CRS_CONSTR_12, 0, "keplerCrs"}, {ATF_NOFLAGS, 0, offsetof(struct NavModel_KeplerianSet, keplerCis), - (ASN_TAG_CLASS_CONTEXT | (11 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_keplerCis_constraint_1, - &ASN_PER_MEMB_KEPLER_CIS_CONSTR_13, 0, "keplerCis"}, + (ASN_TAG_CLASS_CONTEXT | (11 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_keplerCis_constraint_1, + &ASN_PER_MEMB_KEPLER_CIS_CONSTR_13, 0, "keplerCis"}, {ATF_NOFLAGS, 0, offsetof(struct NavModel_KeplerianSet, keplerCus), - (ASN_TAG_CLASS_CONTEXT | (12 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_keplerCus_constraint_1, - &ASN_PER_MEMB_KEPLER_CUS_CONSTR_14, 0, "keplerCus"}, + (ASN_TAG_CLASS_CONTEXT | (12 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_keplerCus_constraint_1, + &ASN_PER_MEMB_KEPLER_CUS_CONSTR_14, 0, "keplerCus"}, {ATF_NOFLAGS, 0, offsetof(struct NavModel_KeplerianSet, keplerCrc), - (ASN_TAG_CLASS_CONTEXT | (13 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_keplerCrc_constraint_1, - &ASN_PER_MEMB_KEPLER_CRC_CONSTR_15, 0, "keplerCrc"}, + (ASN_TAG_CLASS_CONTEXT | (13 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_keplerCrc_constraint_1, + &ASN_PER_MEMB_KEPLER_CRC_CONSTR_15, 0, "keplerCrc"}, {ATF_NOFLAGS, 0, offsetof(struct NavModel_KeplerianSet, keplerCic), - (ASN_TAG_CLASS_CONTEXT | (14 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_keplerCic_constraint_1, - &ASN_PER_MEMB_KEPLER_CIC_CONSTR_16, 0, "keplerCic"}, + (ASN_TAG_CLASS_CONTEXT | (14 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_keplerCic_constraint_1, + &ASN_PER_MEMB_KEPLER_CIC_CONSTR_16, 0, "keplerCic"}, {ATF_NOFLAGS, 0, offsetof(struct NavModel_KeplerianSet, keplerCuc), - (ASN_TAG_CLASS_CONTEXT | (15 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_keplerCuc_constraint_1, - &ASN_PER_MEMB_KEPLER_CUC_CONSTR_17, 0, "keplerCuc"}, + (ASN_TAG_CLASS_CONTEXT | (15 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_keplerCuc_constraint_1, + &ASN_PER_MEMB_KEPLER_CUC_CONSTR_17, 0, "keplerCuc"}, }; static ber_tlv_tag_t asn_DEF_NavModel_KeplerianSet_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -652,7 +652,7 @@ static asn_TYPE_tag2member_t asn_MAP_NavModel_KeplerianSet_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (5 << 2)), 5, 0, 0}, /* keplerELSB at 1259 */ {(ASN_TAG_CLASS_CONTEXT | (6 << 2)), 6, 0, 0}, /* keplerIDot at 1260 */ {(ASN_TAG_CLASS_CONTEXT | (7 << 2)), 7, 0, - 0}, /* keplerAPowerHalfLSB at 1261 */ + 0}, /* keplerAPowerHalfLSB at 1261 */ {(ASN_TAG_CLASS_CONTEXT | (8 << 2)), 8, 0, 0}, /* keplerI0 at 1262 */ {(ASN_TAG_CLASS_CONTEXT | (9 << 2)), 9, 0, 0}, /* keplerOmega0 at 1263 */ {(ASN_TAG_CLASS_CONTEXT | (10 << 2)), 10, 0, 0}, /* keplerCrs at 1264 */ @@ -692,7 +692,7 @@ asn_TYPE_descriptor_t asn_DEF_NavModel_KeplerianSet = { asn_DEF_NavModel_KeplerianSet_tags_1, /* Same as above */ sizeof(asn_DEF_NavModel_KeplerianSet_tags_1) / sizeof(asn_DEF_NavModel_KeplerianSet_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_NavModel_KeplerianSet_1, 16, /* Elements count */ &asn_SPC_NavModel_KeplerianSet_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/NavModelElement.c b/src/core/libs/supl/asn-rrlp/NavModelElement.c index b0637344a..59bab38ef 100644 --- a/src/core/libs/supl/asn-rrlp/NavModelElement.c +++ b/src/core/libs/supl/asn-rrlp/NavModelElement.c @@ -8,16 +8,16 @@ static asn_TYPE_member_t asn_MBR_NavModelElement_1[] = { {ATF_NOFLAGS, 0, offsetof(struct NavModelElement, satelliteID), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SatelliteID, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "satelliteID"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SatelliteID, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "satelliteID"}, {ATF_NOFLAGS, 0, offsetof(struct NavModelElement, satStatus), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), +1, /* EXPLICIT tag at current level */ - &asn_DEF_SatStatus, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "satStatus"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), +1, /* EXPLICIT tag at current level */ + &asn_DEF_SatStatus, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "satStatus"}, }; static ber_tlv_tag_t asn_DEF_NavModelElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -55,7 +55,7 @@ asn_TYPE_descriptor_t asn_DEF_NavModelElement = { asn_DEF_NavModelElement_tags_1, /* Same as above */ sizeof(asn_DEF_NavModelElement_tags_1) / sizeof(asn_DEF_NavModelElement_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_NavModelElement_1, 2, /* Elements count */ &asn_SPC_NavModelElement_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/NavModelElement.h b/src/core/libs/supl/asn-rrlp/NavModelElement.h index 26cc9f352..beb930558 100644 --- a/src/core/libs/supl/asn-rrlp/NavModelElement.h +++ b/src/core/libs/supl/asn-rrlp/NavModelElement.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include "SatelliteID.h" #include "SatStatus.h" +#include "SatelliteID.h" #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/NavigationModel.c b/src/core/libs/supl/asn-rrlp/NavigationModel.c index ad132ef17..40d2bacd6 100644 --- a/src/core/libs/supl/asn-rrlp/NavigationModel.c +++ b/src/core/libs/supl/asn-rrlp/NavigationModel.c @@ -8,11 +8,11 @@ static asn_TYPE_member_t asn_MBR_NavigationModel_1[] = { {ATF_NOFLAGS, 0, offsetof(struct NavigationModel, navModelList), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfNavModelElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "navModelList"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfNavModelElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "navModelList"}, }; static ber_tlv_tag_t asn_DEF_NavigationModel_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -49,7 +49,7 @@ asn_TYPE_descriptor_t asn_DEF_NavigationModel = { asn_DEF_NavigationModel_tags_1, /* Same as above */ sizeof(asn_DEF_NavigationModel_tags_1) / sizeof(asn_DEF_NavigationModel_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_NavigationModel_1, 1, /* Elements count */ &asn_SPC_NavigationModel_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/NeighborIdentity.c b/src/core/libs/supl/asn-rrlp/NeighborIdentity.c index c932fd1f0..28e51d139 100644 --- a/src/core/libs/supl/asn-rrlp/NeighborIdentity.c +++ b/src/core/libs/supl/asn-rrlp/NeighborIdentity.c @@ -14,47 +14,47 @@ static asn_per_constraints_t ASN_PER_TYPE_NEIGHBOR_IDENTITY_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_NeighborIdentity_1[] = { {ATF_NOFLAGS, 0, offsetof(struct NeighborIdentity, choice.bsicAndCarrier), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BSICAndCarrier, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "bsicAndCarrier"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BSICAndCarrier, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "bsicAndCarrier"}, {ATF_NOFLAGS, 0, offsetof(struct NeighborIdentity, choice.ci), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_CellID, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ci"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_CellID, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ci"}, {ATF_NOFLAGS, 0, - offsetof(struct NeighborIdentity, choice.multiFrameCarrier), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_MultiFrameCarrier, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "multiFrameCarrier"}, + offsetof(struct NeighborIdentity, choice.multiFrameCarrier), + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_MultiFrameCarrier, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "multiFrameCarrier"}, {ATF_NOFLAGS, 0, offsetof(struct NeighborIdentity, choice.requestIndex), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_RequestIndex, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "requestIndex"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_RequestIndex, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "requestIndex"}, {ATF_NOFLAGS, 0, offsetof(struct NeighborIdentity, choice.systemInfoIndex), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SystemInfoIndex, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "systemInfoIndex"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SystemInfoIndex, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "systemInfoIndex"}, {ATF_NOFLAGS, 0, offsetof(struct NeighborIdentity, choice.ciAndLAC), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_CellIDAndLAC, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ciAndLAC"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_CellIDAndLAC, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ciAndLAC"}, }; static asn_TYPE_tag2member_t asn_MAP_NeighborIdentity_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* bsicAndCarrier at 398 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0}, /* ci at 399 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, - 0}, /* multiFrameCarrier at 400 */ + 0}, /* multiFrameCarrier at 400 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, 0}, /* requestIndex at 401 */ {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, 0}, /* systemInfoIndex at 402 */ {(ASN_TAG_CLASS_CONTEXT | (5 << 2)), 5, 0, 0} /* ciAndLAC at 407 */ diff --git a/src/core/libs/supl/asn-rrlp/NeighborIdentity.h b/src/core/libs/supl/asn-rrlp/NeighborIdentity.h index 8923e9e4a..f4c60127b 100644 --- a/src/core/libs/supl/asn-rrlp/NeighborIdentity.h +++ b/src/core/libs/supl/asn-rrlp/NeighborIdentity.h @@ -12,10 +12,10 @@ /* Including external dependencies */ #include "BSICAndCarrier.h" #include "CellID.h" +#include "CellIDAndLAC.h" #include "MultiFrameCarrier.h" #include "RequestIndex.h" #include "SystemInfoIndex.h" -#include "CellIDAndLAC.h" #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/NumOfMeasurements.c b/src/core/libs/supl/asn-rrlp/NumOfMeasurements.c index df8d88813..442e3c843 100644 --- a/src/core/libs/supl/asn-rrlp/NumOfMeasurements.c +++ b/src/core/libs/supl/asn-rrlp/NumOfMeasurements.c @@ -7,15 +7,15 @@ #include "NumOfMeasurements.h" int NumOfMeasurements_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ int NumOfMeasurements_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -57,77 +57,77 @@ static void NumOfMeasurements_1_inherit_TYPE_descriptor( } void NumOfMeasurements_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { NumOfMeasurements_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int NumOfMeasurements_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, + void *app_key) { NumOfMeasurements_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t NumOfMeasurements_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, + const void *bufptr, size_t size, + int tag_mode) { NumOfMeasurements_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t NumOfMeasurements_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { NumOfMeasurements_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t NumOfMeasurements_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { NumOfMeasurements_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t NumOfMeasurements_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { NumOfMeasurements_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t NumOfMeasurements_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { NumOfMeasurements_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t NumOfMeasurements_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { NumOfMeasurements_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/OCTET_STRING.c b/src/core/libs/supl/asn-rrlp/OCTET_STRING.c index e66360994..b092caadf 100644 --- a/src/core/libs/supl/asn-rrlp/OCTET_STRING.c +++ b/src/core/libs/supl/asn-rrlp/OCTET_STRING.c @@ -3,9 +3,9 @@ * All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ -#include -#include #include /* for .bits_unused member */ +#include +#include #include /* @@ -182,9 +182,9 @@ static struct _stack *_new_stack() * Decode OCTET STRING type. */ asn_dec_rval_t OCTET_STRING_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **sptr, - const void *buf_ptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, void **sptr, + const void *buf_ptr, size_t size, + int tag_mode) { asn_OCTET_STRING_specifics_t *specs = td->specifics ? (asn_OCTET_STRING_specifics_t *)td->specifics @@ -217,351 +217,351 @@ asn_dec_rval_t OCTET_STRING_decode_ber(asn_codec_ctx_t *opt_codec_ctx, switch (ctx->phase) { - case 0: - /* + case 0: + /* * Check tags. */ - rval = ber_check_tags(opt_codec_ctx, td, ctx, buf_ptr, size, - tag_mode, -1, &ctx->left, &tlv_constr); - if (rval.code != RC_OK) return rval; + rval = ber_check_tags(opt_codec_ctx, td, ctx, buf_ptr, size, + tag_mode, -1, &ctx->left, &tlv_constr); + if (rval.code != RC_OK) return rval; - if (tlv_constr) - { - /* + if (tlv_constr) + { + /* * Complex operation, requires stack of expectations. */ - ctx->ptr = _new_stack(); - if (ctx->ptr) - { - stck = (struct _stack *)ctx->ptr; - } - else - { - RETURN(RC_FAIL); - } - } - else - { - /* + ctx->ptr = _new_stack(); + if (ctx->ptr) + { + stck = (struct _stack *)ctx->ptr; + } + else + { + RETURN(RC_FAIL); + } + } + else + { + /* * Jump into stackless primitive decoding. */ - _CH_PHASE(ctx, 3); - if (type_variant == ASN_OSUBV_ANY && tag_mode != 1) - APPEND(buf_ptr, rval.consumed); - ADVANCE(rval.consumed); - goto phase3; - } + _CH_PHASE(ctx, 3); + if (type_variant == ASN_OSUBV_ANY && tag_mode != 1) + APPEND(buf_ptr, rval.consumed); + ADVANCE(rval.consumed); + goto phase3; + } - NEXT_PHASE(ctx); - /* Fall through */ - case 1: - phase1: - /* + NEXT_PHASE(ctx); + /* Fall through */ + case 1: + phase1: + /* * Fill the stack with expectations. */ - stck = (struct _stack *)ctx->ptr; - sel = stck->cur_ptr; - do - { - ber_tlv_tag_t tlv_tag; - ber_tlv_len_t tlv_len; - ber_tlv_tag_t expected_tag; - ssize_t tl; - ssize_t ll; - ssize_t tlvl; - /* This one works even if (sel->left == -1) */ - ssize_t Left = - ((!sel || (size_t)sel->left >= size) ? (ssize_t)size - : sel->left); - - ASN_DEBUG("%p, s->l=%ld, s->wn=%ld, s->g=%ld\n", sel, - (sel ? sel->left : 0), - (long)(sel ? sel->want_nulls : 0), - (sel ? sel->got : 0)); - if (sel && sel->left <= 0 && sel->want_nulls == 0) - { - if (sel->prev) - { - struct _stack_el *prev = sel->prev; - if (prev->left != -1) - { - if (prev->left < sel->got) - RETURN(RC_FAIL); - prev->left -= sel->got; - } - prev->got += sel->got; - sel = stck->cur_ptr = prev; - if (!sel) break; - tlv_constr = 1; - continue; - } - else - { - sel = stck->cur_ptr = 0; - break; /* Nothing to wait */ - } - } - - tl = ber_fetch_tag(buf_ptr, Left, &tlv_tag); - ASN_DEBUG( - "fetch tag(size=%ld,L=%ld), %sstack, left=%ld, " - "wn=%ld, " - "tl=%ld", - (long)size, (long)Left, sel ? "" : "!", - (sel ? sel->left : 0), - (long)(sel ? sel->want_nulls : 0), (long)tl); - switch (tl) - { - case -1: - RETURN(RC_FAIL); - case 0: - RETURN(RC_WMORE); - } - - tlv_constr = BER_TLV_CONSTRUCTED(buf_ptr); - - ll = ber_fetch_length(tlv_constr, - (const char *)buf_ptr + tl, - Left - tl, &tlv_len); - ASN_DEBUG( - "Got tag=%s, tc=%d, left=%ld, tl=%ld, len=%ld, " - "ll=%ld", - ber_tlv_tag_string(tlv_tag), tlv_constr, (long)Left, - (long)tl, (long)tlv_len, (long)ll); - switch (ll) - { - case -1: - RETURN(RC_FAIL); - case 0: - RETURN(RC_WMORE); - } - - if (sel && sel->want_nulls && - ((const uint8_t *)buf_ptr)[0] == 0 && - ((const uint8_t *)buf_ptr)[1] == 0) - { - ASN_DEBUG("Eat EOC; wn=%d--", sel->want_nulls); - - if (type_variant == ASN_OSUBV_ANY && - (tag_mode != 1 || sel->cont_level)) - APPEND("\0\0", 2); - - ADVANCE(2); - sel->got += 2; - if (sel->left != -1) - { - sel->left -= - 2; /* assert(sel->left >= 2) */ - } - - sel->want_nulls--; - if (sel->want_nulls == 0) - { - /* Move to the next expectation */ - sel->left = 0; - tlv_constr = 1; - } - - continue; - } - - /* - * Set up expected tags, - * depending on ASN.1 type being decoded. - */ - switch (type_variant) - { - case ASN_OSUBV_BIT: - /* X.690: 8.6.4.1, NOTE 2 */ - /* Fall through */ - case ASN_OSUBV_STR: - default: - if (sel) - { - int level = sel->cont_level; - if (level < td->all_tags_count) - { - expected_tag = - td->all_tags[level]; - break; - } - else if (td->all_tags_count) - { - expected_tag = - td->all_tags - [td->all_tags_count - - 1]; - break; - } - /* else, Fall through */ - } - /* Fall through */ - case ASN_OSUBV_ANY: - expected_tag = tlv_tag; - break; - } - - if (tlv_tag != expected_tag) - { - char buf[2][32]; - ber_tlv_tag_snprint(tlv_tag, buf[0], - sizeof(buf[0])); - ber_tlv_tag_snprint( - td->tags[td->tags_count - 1], buf[1], - sizeof(buf[1])); - ASN_DEBUG( - "Tag does not match expectation: %s != %s", - buf[0], buf[1]); - RETURN(RC_FAIL); - } - - tlvl = - tl + ll; /* Combined length of T and L encoding */ - if ((tlv_len + tlvl) < 0) - { - /* tlv_len value is too big */ - ASN_DEBUG( - "TLV encoding + length (%ld) is too big", - (long)tlv_len); - RETURN(RC_FAIL); - } - - /* - * Append a new expectation. - */ - sel = OS__add_stack_el(stck); - if (!sel) RETURN(RC_FAIL); - - sel->tag = tlv_tag; - - sel->want_nulls = (tlv_len == -1); - if (sel->prev && sel->prev->left != -1) - { - /* Check that the parent frame is big enough */ - if (sel->prev->left < - tlvl + (tlv_len == -1 ? 0 : tlv_len)) - RETURN(RC_FAIL); - if (tlv_len == -1) - sel->left = sel->prev->left - tlvl; - else - sel->left = tlv_len; - } - else - { - sel->left = tlv_len; - } - if (type_variant == ASN_OSUBV_ANY && - (tag_mode != 1 || sel->cont_level)) - APPEND(buf_ptr, tlvl); - sel->got += tlvl; - ADVANCE(tlvl); - - ASN_DEBUG("+EXPECT2 got=%ld left=%ld, wn=%d, clvl=%d", - (long)sel->got, (long)sel->left, - sel->want_nulls, sel->cont_level); - } - while (tlv_constr); - if (sel == NULL) - { - /* Finished operation, "phase out" */ - ASN_DEBUG("Phase out"); - _CH_PHASE(ctx, +3); - break; - } - - NEXT_PHASE(ctx); - /* Fall through */ - case 2: - stck = (struct _stack *)ctx->ptr; - sel = stck->cur_ptr; - ASN_DEBUG("Phase 2: Need %ld bytes, size=%ld, alrg=%ld, wn=%d", - (long)sel->left, (long)size, (long)sel->got, - sel->want_nulls); + stck = (struct _stack *)ctx->ptr; + sel = stck->cur_ptr; + do { - ber_tlv_len_t len; + ber_tlv_tag_t tlv_tag; + ber_tlv_len_t tlv_len; + ber_tlv_tag_t expected_tag; + ssize_t tl; + ssize_t ll; + ssize_t tlvl; + /* This one works even if (sel->left == -1) */ + ssize_t Left = + ((!sel || (size_t)sel->left >= size) ? (ssize_t)size + : sel->left); - assert(sel->left >= 0); - - len = ((ber_tlv_len_t)size < sel->left) - ? (ber_tlv_len_t)size - : sel->left; - if (len > 0) + ASN_DEBUG("%p, s->l=%ld, s->wn=%ld, s->g=%ld\n", sel, + (sel ? sel->left : 0), + (long)(sel ? sel->want_nulls : 0), + (sel ? sel->got : 0)); + if (sel && sel->left <= 0 && sel->want_nulls == 0) { - if (type_variant == ASN_OSUBV_BIT && - sel->bits_chopped == 0) + if (sel->prev) { - /* Put the unused-bits-octet away */ - st->bits_unused = *(const uint8_t *)buf_ptr; - APPEND(((const char *)buf_ptr + 1), - (len - 1)); - sel->bits_chopped = 1; + struct _stack_el *prev = sel->prev; + if (prev->left != -1) + { + if (prev->left < sel->got) + RETURN(RC_FAIL); + prev->left -= sel->got; + } + prev->got += sel->got; + sel = stck->cur_ptr = prev; + if (!sel) break; + tlv_constr = 1; + continue; } else { - APPEND(buf_ptr, len); + sel = stck->cur_ptr = 0; + break; /* Nothing to wait */ } - ADVANCE(len); - sel->left -= len; - sel->got += len; } - if (sel->left) + tl = ber_fetch_tag(buf_ptr, Left, &tlv_tag); + ASN_DEBUG( + "fetch tag(size=%ld,L=%ld), %sstack, left=%ld, " + "wn=%ld, " + "tl=%ld", + (long)size, (long)Left, sel ? "" : "!", + (sel ? sel->left : 0), + (long)(sel ? sel->want_nulls : 0), (long)tl); + switch (tl) { - ASN_DEBUG("OS left %ld, size = %ld, wn=%d\n", - (long)sel->left, (long)size, - sel->want_nulls); + case -1: + RETURN(RC_FAIL); + case 0: RETURN(RC_WMORE); } - PREV_PHASE(ctx); - goto phase1; - } - break; - case 3: - phase3: - /* - * Primitive form, no stack required. - */ - assert(ctx->left >= 0); + tlv_constr = BER_TLV_CONSTRUCTED(buf_ptr); - if (size < (size_t)ctx->left) + ll = ber_fetch_length(tlv_constr, + (const char *)buf_ptr + tl, + Left - tl, &tlv_len); + ASN_DEBUG( + "Got tag=%s, tc=%d, left=%ld, tl=%ld, len=%ld, " + "ll=%ld", + ber_tlv_tag_string(tlv_tag), tlv_constr, (long)Left, + (long)tl, (long)tlv_len, (long)ll); + switch (ll) + { + case -1: + RETURN(RC_FAIL); + case 0: + RETURN(RC_WMORE); + } + + if (sel && sel->want_nulls && + ((const uint8_t *)buf_ptr)[0] == 0 && + ((const uint8_t *)buf_ptr)[1] == 0) + { + ASN_DEBUG("Eat EOC; wn=%d--", sel->want_nulls); + + if (type_variant == ASN_OSUBV_ANY && + (tag_mode != 1 || sel->cont_level)) + APPEND("\0\0", 2); + + ADVANCE(2); + sel->got += 2; + if (sel->left != -1) + { + sel->left -= + 2; /* assert(sel->left >= 2) */ + } + + sel->want_nulls--; + if (sel->want_nulls == 0) + { + /* Move to the next expectation */ + sel->left = 0; + tlv_constr = 1; + } + + continue; + } + + /* + * Set up expected tags, + * depending on ASN.1 type being decoded. + */ + switch (type_variant) + { + case ASN_OSUBV_BIT: + /* X.690: 8.6.4.1, NOTE 2 */ + /* Fall through */ + case ASN_OSUBV_STR: + default: + if (sel) + { + int level = sel->cont_level; + if (level < td->all_tags_count) + { + expected_tag = + td->all_tags[level]; + break; + } + else if (td->all_tags_count) + { + expected_tag = + td->all_tags + [td->all_tags_count - + 1]; + break; + } + /* else, Fall through */ + } + /* Fall through */ + case ASN_OSUBV_ANY: + expected_tag = tlv_tag; + break; + } + + if (tlv_tag != expected_tag) + { + char buf[2][32]; + ber_tlv_tag_snprint(tlv_tag, buf[0], + sizeof(buf[0])); + ber_tlv_tag_snprint( + td->tags[td->tags_count - 1], buf[1], + sizeof(buf[1])); + ASN_DEBUG( + "Tag does not match expectation: %s != %s", + buf[0], buf[1]); + RETURN(RC_FAIL); + } + + tlvl = + tl + ll; /* Combined length of T and L encoding */ + if ((tlv_len + tlvl) < 0) + { + /* tlv_len value is too big */ + ASN_DEBUG( + "TLV encoding + length (%ld) is too big", + (long)tlv_len); + RETURN(RC_FAIL); + } + + /* + * Append a new expectation. + */ + sel = OS__add_stack_el(stck); + if (!sel) RETURN(RC_FAIL); + + sel->tag = tlv_tag; + + sel->want_nulls = (tlv_len == -1); + if (sel->prev && sel->prev->left != -1) + { + /* Check that the parent frame is big enough */ + if (sel->prev->left < + tlvl + (tlv_len == -1 ? 0 : tlv_len)) + RETURN(RC_FAIL); + if (tlv_len == -1) + sel->left = sel->prev->left - tlvl; + else + sel->left = tlv_len; + } + else + { + sel->left = tlv_len; + } + if (type_variant == ASN_OSUBV_ANY && + (tag_mode != 1 || sel->cont_level)) + APPEND(buf_ptr, tlvl); + sel->got += tlvl; + ADVANCE(tlvl); + + ASN_DEBUG("+EXPECT2 got=%ld left=%ld, wn=%d, clvl=%d", + (long)sel->got, (long)sel->left, + sel->want_nulls, sel->cont_level); + } + while (tlv_constr); + if (sel == NULL) + { + /* Finished operation, "phase out" */ + ASN_DEBUG("Phase out"); + _CH_PHASE(ctx, +3); + break; + } + + NEXT_PHASE(ctx); + /* Fall through */ + case 2: + stck = (struct _stack *)ctx->ptr; + sel = stck->cur_ptr; + ASN_DEBUG("Phase 2: Need %ld bytes, size=%ld, alrg=%ld, wn=%d", + (long)sel->left, (long)size, (long)sel->got, + sel->want_nulls); + { + ber_tlv_len_t len; + + assert(sel->left >= 0); + + len = ((ber_tlv_len_t)size < sel->left) + ? (ber_tlv_len_t)size + : sel->left; + if (len > 0) { - if (!size) RETURN(RC_WMORE); - if (type_variant == ASN_OSUBV_BIT && !ctx->context) + if (type_variant == ASN_OSUBV_BIT && + sel->bits_chopped == 0) { + /* Put the unused-bits-octet away */ st->bits_unused = *(const uint8_t *)buf_ptr; - ctx->left--; - ADVANCE(1); + APPEND(((const char *)buf_ptr + 1), + (len - 1)); + sel->bits_chopped = 1; } - APPEND(buf_ptr, size); - assert(ctx->context > 0); - ctx->left -= size; - ADVANCE(size); + else + { + APPEND(buf_ptr, len); + } + ADVANCE(len); + sel->left -= len; + sel->got += len; + } + + if (sel->left) + { + ASN_DEBUG("OS left %ld, size = %ld, wn=%d\n", + (long)sel->left, (long)size, + sel->want_nulls); RETURN(RC_WMORE); } - else - { - if (type_variant == ASN_OSUBV_BIT && !ctx->context && - ctx->left) - { - st->bits_unused = *(const uint8_t *)buf_ptr; - ctx->left--; - ADVANCE(1); - } - APPEND(buf_ptr, ctx->left); - ADVANCE(ctx->left); - ctx->left = 0; - NEXT_PHASE(ctx); - } - break; + PREV_PHASE(ctx); + goto phase1; + } + break; + case 3: + phase3: + /* + * Primitive form, no stack required. + */ + assert(ctx->left >= 0); + + if (size < (size_t)ctx->left) + { + if (!size) RETURN(RC_WMORE); + if (type_variant == ASN_OSUBV_BIT && !ctx->context) + { + st->bits_unused = *(const uint8_t *)buf_ptr; + ctx->left--; + ADVANCE(1); + } + APPEND(buf_ptr, size); + assert(ctx->context > 0); + ctx->left -= size; + ADVANCE(size); + RETURN(RC_WMORE); + } + else + { + if (type_variant == ASN_OSUBV_BIT && !ctx->context && + ctx->left) + { + st->bits_unused = *(const uint8_t *)buf_ptr; + ctx->left--; + ADVANCE(1); + } + APPEND(buf_ptr, ctx->left); + ADVANCE(ctx->left); + ctx->left = 0; + + NEXT_PHASE(ctx); + } + break; } if (sel) { ASN_DEBUG("3sel p=%p, wn=%d, l=%ld, g=%ld, size=%ld", sel->prev, - sel->want_nulls, (long)sel->left, (long)sel->got, - (long)size); + sel->want_nulls, (long)sel->left, (long)sel->got, + (long)size); if (sel->prev || sel->want_nulls > 1 || sel->left > 0) { RETURN(RC_WMORE); @@ -578,9 +578,9 @@ asn_dec_rval_t OCTET_STRING_decode_ber(asn_codec_ctx_t *opt_codec_ctx, } ASN_DEBUG("Took %ld bytes to encode %s: [%s]:%ld", (long)consumed_myself, - td->name, - (type_variant == ASN_OSUBV_STR) ? (char *)st->buf : "", - (long)st->size); + td->name, + (type_variant == ASN_OSUBV_STR) ? (char *)st->buf : "", + (long)st->size); RETURN(RC_OK); } @@ -589,9 +589,9 @@ asn_dec_rval_t OCTET_STRING_decode_ber(asn_codec_ctx_t *opt_codec_ctx, * Encode OCTET STRING type using DER. */ asn_enc_rval_t OCTET_STRING_encode_der(asn_TYPE_descriptor_t *td, void *sptr, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { asn_enc_rval_t er; asn_OCTET_STRING_specifics_t *specs = @@ -602,7 +602,7 @@ asn_enc_rval_t OCTET_STRING_encode_der(asn_TYPE_descriptor_t *td, void *sptr, int fix_last_byte = 0; ASN_DEBUG("%s %s as OCTET STRING", cb ? "Estimating" : "Encoding", - td->name); + td->name); /* * Write tags. @@ -660,10 +660,10 @@ cb_failed: } asn_enc_rval_t OCTET_STRING_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, - int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { static const char *h2c = "0123456789ABCDEF"; const OCTET_STRING_t *st = (const OCTET_STRING_t *)sptr; @@ -718,7 +718,7 @@ asn_enc_rval_t OCTET_STRING_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, } if (p - scratch) { - p--; /* Remove the tail space */ + p--; /* Remove the tail space */ _ASN_CALLBACK(scratch, p - scratch); /* Dump the rest */ er.encoded += p - scratch; if (st->size > 16) _i_ASN_TEXT_INDENT(1, ilevel - 1); @@ -824,8 +824,8 @@ static int OS__check_escaped_control_char(const void *buf, int size) } static int OCTET_STRING__handle_control_chars(void *struct_ptr, - const void *chunk_buf, - size_t chunk_size) + const void *chunk_buf, + size_t chunk_size) { /* * This might be one of the escape sequences @@ -850,10 +850,10 @@ static int OCTET_STRING__handle_control_chars(void *struct_ptr, } asn_enc_rval_t OCTET_STRING_encode_xer_utf8(asn_TYPE_descriptor_t *td, - void *sptr, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *sptr, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { const OCTET_STRING_t *st = (const OCTET_STRING_t *)sptr; asn_enc_rval_t er; @@ -883,7 +883,7 @@ asn_enc_rval_t OCTET_STRING_encode_xer_utf8(asn_TYPE_descriptor_t *td, { if (((buf - ss) && cb(ss, buf - ss, app_key) < 0) || cb(OCTET_STRING__xer_escape_table[ch].string, s_len, - app_key) < 0) + app_key) < 0) _ASN_ENCODE_FAILED; encoded_len += (buf - ss) + s_len; ss = buf + 1; @@ -901,9 +901,9 @@ asn_enc_rval_t OCTET_STRING_encode_xer_utf8(asn_TYPE_descriptor_t *td, * Convert from hexadecimal format (cstring): "AB CD EF" */ static ssize_t OCTET_STRING__convert_hexadecimal(void *sptr, - const void *chunk_buf, - size_t chunk_size, - int have_more) + const void *chunk_buf, + size_t chunk_size, + int have_more) { OCTET_STRING_t *st = (OCTET_STRING_t *)sptr; const char *chunk_stop = (const char *)chunk_buf; @@ -930,44 +930,44 @@ static ssize_t OCTET_STRING__convert_hexadecimal(void *sptr, int ch = *(const unsigned char *)p; switch (ch) { - case 0x09: - case 0x0a: - case 0x0c: - case 0x0d: - case 0x20: - /* Ignore whitespace */ - continue; - case 0x30: - case 0x31: - case 0x32: - case 0x33: - case 0x34: /*01234*/ - case 0x35: - case 0x36: - case 0x37: - case 0x38: - case 0x39: /*56789*/ - clv = (clv << 4) + (ch - 0x30); - break; - case 0x41: - case 0x42: - case 0x43: /* ABC */ - case 0x44: - case 0x45: - case 0x46: /* DEF */ - clv = (clv << 4) + (ch - 0x41 + 10); - break; - case 0x61: - case 0x62: - case 0x63: /* abc */ - case 0x64: - case 0x65: - case 0x66: /* def */ - clv = (clv << 4) + (ch - 0x61 + 10); - break; - default: - *buf = 0; /* JIC */ - return -1; + case 0x09: + case 0x0a: + case 0x0c: + case 0x0d: + case 0x20: + /* Ignore whitespace */ + continue; + case 0x30: + case 0x31: + case 0x32: + case 0x33: + case 0x34: /*01234*/ + case 0x35: + case 0x36: + case 0x37: + case 0x38: + case 0x39: /*56789*/ + clv = (clv << 4) + (ch - 0x30); + break; + case 0x41: + case 0x42: + case 0x43: /* ABC */ + case 0x44: + case 0x45: + case 0x46: /* DEF */ + clv = (clv << 4) + (ch - 0x41 + 10); + break; + case 0x61: + case 0x62: + case 0x63: /* abc */ + case 0x64: + case 0x65: + case 0x66: /* def */ + clv = (clv << 4) + (ch - 0x61 + 10); + break; + default: + *buf = 0; /* JIC */ + return -1; } if (half++) { @@ -1008,7 +1008,7 @@ static ssize_t OCTET_STRING__convert_hexadecimal(void *sptr, * Convert from binary format: "00101011101" */ static ssize_t OCTET_STRING__convert_binary(void *sptr, const void *chunk_buf, - size_t chunk_size, int have_more) + size_t chunk_size, int have_more) { BIT_STRING_t *st = (BIT_STRING_t *)sptr; const char *p = (const char *)chunk_buf; @@ -1038,25 +1038,25 @@ static ssize_t OCTET_STRING__convert_binary(void *sptr, const void *chunk_buf, int ch = *(const unsigned char *)p; switch (ch) { - case 0x09: - case 0x0a: - case 0x0c: - case 0x0d: - case 0x20: - /* Ignore whitespace */ - break; - case 0x30: - case 0x31: - if (bits_unused-- <= 0) - { - *++buf = 0; /* Clean the cell */ - bits_unused = 7; - } - *buf |= (ch & 1) << bits_unused; - break; - default: - st->bits_unused = bits_unused; - return -1; + case 0x09: + case 0x0a: + case 0x0c: + case 0x0d: + case 0x20: + /* Ignore whitespace */ + break; + case 0x30: + case 0x31: + if (bits_unused-- <= 0) + { + *++buf = 0; /* Clean the cell */ + bits_unused = 7; + } + *buf |= (ch & 1) << bits_unused; + break; + default: + st->bits_unused = bits_unused; + return -1; } } @@ -1081,7 +1081,7 @@ static ssize_t OCTET_STRING__convert_binary(void *sptr, const void *chunk_buf, * Something like strtod(), but with stricter rules. */ static int OS__strtoent(int base, const char *buf, const char *end, - int32_t *ret_value) + int32_t *ret_value) { int32_t val = 0; const char *p; @@ -1095,39 +1095,39 @@ static int OS__strtoent(int base, const char *buf, const char *end, switch (ch) { - case 0x30: - case 0x31: - case 0x32: - case 0x33: - case 0x34: /*01234*/ - case 0x35: - case 0x36: - case 0x37: - case 0x38: - case 0x39: /*56789*/ - val = val * base + (ch - 0x30); - break; - case 0x41: - case 0x42: - case 0x43: /* ABC */ - case 0x44: - case 0x45: - case 0x46: /* DEF */ - val = val * base + (ch - 0x41 + 10); - break; - case 0x61: - case 0x62: - case 0x63: /* abc */ - case 0x64: - case 0x65: - case 0x66: /* def */ - val = val * base + (ch - 0x61 + 10); - break; - case 0x3b: /* ';' */ - *ret_value = val; - return (p - buf) + 1; - default: - return -1; /* Character set error */ + case 0x30: + case 0x31: + case 0x32: + case 0x33: + case 0x34: /*01234*/ + case 0x35: + case 0x36: + case 0x37: + case 0x38: + case 0x39: /*56789*/ + val = val * base + (ch - 0x30); + break; + case 0x41: + case 0x42: + case 0x43: /* ABC */ + case 0x44: + case 0x45: + case 0x46: /* DEF */ + val = val * base + (ch - 0x41 + 10); + break; + case 0x61: + case 0x62: + case 0x63: /* abc */ + case 0x64: + case 0x65: + case 0x66: /* def */ + val = val * base + (ch - 0x61 + 10); + break; + case 0x3b: /* ';' */ + *ret_value = val; + return (p - buf) + 1; + default: + return -1; /* Character set error */ } } @@ -1139,7 +1139,7 @@ static int OS__strtoent(int base, const char *buf, const char *end, * Convert from the plain UTF-8 format, expanding entity references: "2 < 3" */ static ssize_t OCTET_STRING__convert_entrefs(void *sptr, const void *chunk_buf, - size_t chunk_size, int have_more) + size_t chunk_size, int have_more) { OCTET_STRING_t *st = (OCTET_STRING_t *)sptr; const char *p = (const char *)chunk_buf; @@ -1309,9 +1309,9 @@ static asn_dec_rval_t OCTET_STRING__decode_xer( asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td, void **sptr, const char *opt_mname, const void *buf_ptr, size_t size, int (*opt_unexpected_tag_decoder)(void *struct_ptr, const void *chunk_buf, - size_t chunk_size), + size_t chunk_size), ssize_t (*body_receiver)(void *struct_ptr, const void *chunk_buf, - size_t chunk_size, int have_more)) + size_t chunk_size, int have_more)) { OCTET_STRING_t *st = (OCTET_STRING_t *)*sptr; asn_OCTET_STRING_specifics_t *specs = @@ -1358,7 +1358,7 @@ static asn_dec_rval_t OCTET_STRING__decode_xer( ctx = (asn_struct_ctx_t *)(((char *)*sptr) + specs->ctx_offset); return xer_decode_general(opt_codec_ctx, ctx, *sptr, xml_tag, buf_ptr, size, - opt_unexpected_tag_decoder, body_receiver); + opt_unexpected_tag_decoder, body_receiver); stb_failed: FREEMEM(st); @@ -1372,49 +1372,49 @@ sta_failed: * Decode OCTET STRING from the hexadecimal data. */ asn_dec_rval_t OCTET_STRING_decode_xer_hex(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **sptr, const char *opt_mname, - const void *buf_ptr, size_t size) + asn_TYPE_descriptor_t *td, + void **sptr, const char *opt_mname, + const void *buf_ptr, size_t size) { return OCTET_STRING__decode_xer(opt_codec_ctx, td, sptr, opt_mname, buf_ptr, - size, 0, OCTET_STRING__convert_hexadecimal); + size, 0, OCTET_STRING__convert_hexadecimal); } /* * Decode OCTET STRING from the binary (0/1) data. */ asn_dec_rval_t OCTET_STRING_decode_xer_binary(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **sptr, - const char *opt_mname, - const void *buf_ptr, size_t size) + asn_TYPE_descriptor_t *td, + void **sptr, + const char *opt_mname, + const void *buf_ptr, size_t size) { return OCTET_STRING__decode_xer(opt_codec_ctx, td, sptr, opt_mname, buf_ptr, - size, 0, OCTET_STRING__convert_binary); + size, 0, OCTET_STRING__convert_binary); } /* * Decode OCTET STRING from the string (ASCII/UTF-8) data. */ asn_dec_rval_t OCTET_STRING_decode_xer_utf8(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **sptr, const char *opt_mname, - const void *buf_ptr, size_t size) + asn_TYPE_descriptor_t *td, + void **sptr, const char *opt_mname, + const void *buf_ptr, size_t size) { return OCTET_STRING__decode_xer(opt_codec_ctx, td, sptr, opt_mname, buf_ptr, - size, OCTET_STRING__handle_control_chars, - OCTET_STRING__convert_entrefs); + size, OCTET_STRING__handle_control_chars, + OCTET_STRING__convert_entrefs); } static int OCTET_STRING_per_get_characters(asn_per_data_t *po, uint8_t *buf, - size_t units, unsigned int bpc, - unsigned int unit_bits, long lb, - long ub, asn_per_constraints_t *pc) + size_t units, unsigned int bpc, + unsigned int unit_bits, long lb, + long ub, asn_per_constraints_t *pc) { uint8_t *end = buf + units * bpc; ASN_DEBUG("Expanding %d characters into (%ld..%ld):%d", (int)units, lb, ub, - unit_bits); + unit_bits); /* X.691: 27.5.4 */ if ((unsigned long)ub <= ((unsigned long)2 << (unit_bits - 1))) @@ -1444,19 +1444,19 @@ static int OCTET_STRING_per_get_characters(asn_per_data_t *po, uint8_t *buf, } switch (bpc) { - case 1: - *buf = value; - break; - case 2: - buf[0] = value >> 8; - buf[1] = value; - break; - case 4: - buf[0] = value >> 24; - buf[1] = value >> 16; - buf[2] = value >> 8; - buf[3] = value; - break; + case 1: + *buf = value; + break; + case 2: + buf[0] = value >> 8; + buf[1] = value; + break; + case 4: + buf[0] = value >> 24; + buf[1] = value >> 16; + buf[2] = value >> 8; + buf[3] = value; + break; } } return 0; @@ -1480,19 +1480,19 @@ static int OCTET_STRING_per_get_characters(asn_per_data_t *po, uint8_t *buf, } switch (bpc) { - case 1: - *buf = ch; - break; - case 2: - buf[0] = ch >> 8; - buf[1] = ch; - break; - case 4: - buf[0] = ch >> 24; - buf[1] = ch >> 16; - buf[2] = ch >> 8; - buf[3] = ch; - break; + case 1: + *buf = ch; + break; + case 2: + buf[0] = ch >> 8; + buf[1] = ch; + break; + case 4: + buf[0] = ch >> 24; + buf[1] = ch >> 16; + buf[2] = ch >> 8; + buf[3] = ch; + break; } } @@ -1500,15 +1500,15 @@ static int OCTET_STRING_per_get_characters(asn_per_data_t *po, uint8_t *buf, } static int OCTET_STRING_per_put_characters(asn_per_outp_t *po, - const uint8_t *buf, size_t units, - unsigned int bpc, - unsigned int unit_bits, long lb, - long ub, asn_per_constraints_t *pc) + const uint8_t *buf, size_t units, + unsigned int bpc, + unsigned int unit_bits, long lb, + long ub, asn_per_constraints_t *pc) { const uint8_t *end = buf + units * bpc; ASN_DEBUG("Squeezing %d characters into (%ld..%ld):%d (%d bpc)", (int)units, - lb, ub, unit_bits, bpc); + lb, ub, unit_bits, bpc); /* X.691: 27.5.4 */ if ((unsigned long)ub <= ((unsigned long)2 << (unit_bits - 1))) @@ -1524,18 +1524,18 @@ static int OCTET_STRING_per_put_characters(asn_per_outp_t *po, uint32_t value; switch (bpc) { - case 1: - value = *buf; - break; - case 2: - value = (buf[0] << 8) | buf[1]; - break; - case 4: - value = (buf[0] << 24) | (buf[1] << 16) | - (buf[2] << 8) | buf[3]; - break; - default: - return -1; + case 1: + value = *buf; + break; + case 2: + value = (buf[0] << 8) | buf[1]; + break; + case 4: + value = (buf[0] << 24) | (buf[1] << 16) | + (buf[2] << 8) | buf[3]; + break; + default: + return -1; } code = pc->value2code(value); if (code < 0) @@ -1562,18 +1562,18 @@ static int OCTET_STRING_per_put_characters(asn_per_outp_t *po, uint32_t value; switch (bpc) { - case 1: - value = *buf; - break; - case 2: - value = (buf[0] << 8) | buf[1]; - break; - case 4: - value = (buf[0] << 24) | (buf[1] << 16) | - (buf[2] << 8) | buf[3]; - break; - default: - return -1; + case 1: + value = *buf; + break; + case 2: + value = (buf[0] << 8) | buf[1]; + break; + case 4: + value = (buf[0] << 24) | (buf[1] << 16) | + (buf[2] << 8) | buf[3]; + break; + default: + return -1; } ch = value - lb; if (ch < 0 || ch > ub) @@ -1591,9 +1591,9 @@ static int OCTET_STRING_per_put_characters(asn_per_outp_t *po, } asn_dec_rval_t OCTET_STRING_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd) { asn_OCTET_STRING_specifics_t *specs = td->specifics ? (asn_OCTET_STRING_specifics_t *)td->specifics @@ -1630,29 +1630,29 @@ asn_dec_rval_t OCTET_STRING_decode_uper(asn_codec_ctx_t *opt_codec_ctx, switch (specs->subvariant) { - default: - case ASN_OSUBV_ANY: - ASN_DEBUG("Unrecognized subvariant %d", specs->subvariant); - RETURN(RC_FAIL); - case ASN_OSUBV_BIT: - canonical_unit_bits = unit_bits = 1; - bpc = OS__BPC_BIT; - break; - case ASN_OSUBV_STR: - canonical_unit_bits = unit_bits = 8; - if (cval->flags & APC_CONSTRAINED) unit_bits = cval->range_bits; - bpc = OS__BPC_CHAR; - break; - case ASN_OSUBV_U16: - canonical_unit_bits = unit_bits = 16; - if (cval->flags & APC_CONSTRAINED) unit_bits = cval->range_bits; - bpc = OS__BPC_U16; - break; - case ASN_OSUBV_U32: - canonical_unit_bits = unit_bits = 32; - if (cval->flags & APC_CONSTRAINED) unit_bits = cval->range_bits; - bpc = OS__BPC_U32; - break; + default: + case ASN_OSUBV_ANY: + ASN_DEBUG("Unrecognized subvariant %d", specs->subvariant); + RETURN(RC_FAIL); + case ASN_OSUBV_BIT: + canonical_unit_bits = unit_bits = 1; + bpc = OS__BPC_BIT; + break; + case ASN_OSUBV_STR: + canonical_unit_bits = unit_bits = 8; + if (cval->flags & APC_CONSTRAINED) unit_bits = cval->range_bits; + bpc = OS__BPC_CHAR; + break; + case ASN_OSUBV_U16: + canonical_unit_bits = unit_bits = 16; + if (cval->flags & APC_CONSTRAINED) unit_bits = cval->range_bits; + bpc = OS__BPC_U16; + break; + case ASN_OSUBV_U32: + canonical_unit_bits = unit_bits = 32; + if (cval->flags & APC_CONSTRAINED) unit_bits = cval->range_bits; + bpc = OS__BPC_U32; + break; } /* @@ -1665,8 +1665,8 @@ asn_dec_rval_t OCTET_STRING_decode_uper(asn_codec_ctx_t *opt_codec_ctx, } ASN_DEBUG("PER Decoding %s size %ld .. %ld bits %d", - csiz->flags & APC_EXTENSIBLE ? "extensible" : "non-extensible", - csiz->lower_bound, csiz->upper_bound, csiz->effective_bits); + csiz->flags & APC_EXTENSIBLE ? "extensible" : "non-extensible", + csiz->lower_bound, csiz->upper_bound, csiz->effective_bits); if (csiz->flags & APC_EXTENSIBLE) { @@ -1708,7 +1708,7 @@ asn_dec_rval_t OCTET_STRING_decode_uper(asn_codec_ctx_t *opt_codec_ctx, if (bpc) { ASN_DEBUG("Encoding OCTET STRING size %ld", - csiz->upper_bound); + csiz->upper_bound); ret = OCTET_STRING_per_get_characters( pd, st->buf, csiz->upper_bound, bpc, unit_bits, cval->lower_bound, cval->upper_bound, pc); @@ -1717,9 +1717,9 @@ asn_dec_rval_t OCTET_STRING_decode_uper(asn_codec_ctx_t *opt_codec_ctx, else { ASN_DEBUG("Encoding BIT STRING size %ld", - csiz->upper_bound); + csiz->upper_bound); ret = per_get_many_bits(pd, st->buf, 0, - unit_bits * csiz->upper_bound); + unit_bits * csiz->upper_bound); } if (ret < 0) RETURN(RC_WMORE); consumed_myself += unit_bits * csiz->upper_bound; @@ -1747,8 +1747,8 @@ asn_dec_rval_t OCTET_STRING_decode_uper(asn_codec_ctx_t *opt_codec_ctx, raw_len += csiz->lower_bound; ASN_DEBUG("Got PER length eb %ld, len %ld, %s (%s)", - (long)csiz->effective_bits, (long)raw_len, - repeat ? "repeat" : "once", td->name); + (long)csiz->effective_bits, (long)raw_len, + repeat ? "repeat" : "once", td->name); if (bpc) { len_bytes = raw_len * bpc; @@ -1787,8 +1787,8 @@ asn_dec_rval_t OCTET_STRING_decode_uper(asn_codec_ctx_t *opt_codec_ctx, } asn_enc_rval_t OCTET_STRING_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *sptr, asn_per_outp_t *po) + asn_per_constraints_t *constraints, + void *sptr, asn_per_outp_t *po) { asn_OCTET_STRING_specifics_t *specs = td->specifics ? (asn_OCTET_STRING_specifics_t *)td->specifics @@ -1829,34 +1829,34 @@ asn_enc_rval_t OCTET_STRING_encode_uper(asn_TYPE_descriptor_t *td, switch (specs->subvariant) { - default: - case ASN_OSUBV_ANY: - _ASN_ENCODE_FAILED; - case ASN_OSUBV_BIT: - canonical_unit_bits = unit_bits = 1; - bpc = OS__BPC_BIT; - sizeinunits = st->size * 8 - (st->bits_unused & 0x07); - ASN_DEBUG("BIT STRING of %d bytes, %d bits unused", sizeinunits, - st->bits_unused); - break; - case ASN_OSUBV_STR: - canonical_unit_bits = unit_bits = 8; - if (cval->flags & APC_CONSTRAINED) unit_bits = cval->range_bits; - bpc = OS__BPC_CHAR; - sizeinunits = st->size; - break; - case ASN_OSUBV_U16: - canonical_unit_bits = unit_bits = 16; - if (cval->flags & APC_CONSTRAINED) unit_bits = cval->range_bits; - bpc = OS__BPC_U16; - sizeinunits = st->size / 2; - break; - case ASN_OSUBV_U32: - canonical_unit_bits = unit_bits = 32; - if (cval->flags & APC_CONSTRAINED) unit_bits = cval->range_bits; - bpc = OS__BPC_U32; - sizeinunits = st->size / 4; - break; + default: + case ASN_OSUBV_ANY: + _ASN_ENCODE_FAILED; + case ASN_OSUBV_BIT: + canonical_unit_bits = unit_bits = 1; + bpc = OS__BPC_BIT; + sizeinunits = st->size * 8 - (st->bits_unused & 0x07); + ASN_DEBUG("BIT STRING of %d bytes, %d bits unused", sizeinunits, + st->bits_unused); + break; + case ASN_OSUBV_STR: + canonical_unit_bits = unit_bits = 8; + if (cval->flags & APC_CONSTRAINED) unit_bits = cval->range_bits; + bpc = OS__BPC_CHAR; + sizeinunits = st->size; + break; + case ASN_OSUBV_U16: + canonical_unit_bits = unit_bits = 16; + if (cval->flags & APC_CONSTRAINED) unit_bits = cval->range_bits; + bpc = OS__BPC_U16; + sizeinunits = st->size / 2; + break; + case ASN_OSUBV_U32: + canonical_unit_bits = unit_bits = 32; + if (cval->flags & APC_CONSTRAINED) unit_bits = cval->range_bits; + bpc = OS__BPC_U32; + sizeinunits = st->size / 4; + break; } ASN_DEBUG( @@ -1900,9 +1900,9 @@ asn_enc_rval_t OCTET_STRING_encode_uper(asn_TYPE_descriptor_t *td, if (csiz->effective_bits >= 0) { ASN_DEBUG("Encoding %d bytes (%ld), length in %d bits", st->size, - sizeinunits - csiz->lower_bound, csiz->effective_bits); + sizeinunits - csiz->lower_bound, csiz->effective_bits); ret = per_put_few_bits(po, sizeinunits - csiz->lower_bound, - csiz->effective_bits); + csiz->effective_bits); if (ret) _ASN_ENCODE_FAILED; if (bpc) { @@ -1959,7 +1959,7 @@ asn_enc_rval_t OCTET_STRING_encode_uper(asn_TYPE_descriptor_t *td, } int OCTET_STRING_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { static const char *h2c = "0123456789ABCDEF"; const OCTET_STRING_t *st = (const OCTET_STRING_t *)sptr; @@ -2002,8 +2002,8 @@ int OCTET_STRING_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, } int OCTET_STRING_print_utf8(asn_TYPE_descriptor_t *td, const void *sptr, - int ilevel, asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, + void *app_key) { const OCTET_STRING_t *st = (const OCTET_STRING_t *)sptr; @@ -2102,7 +2102,7 @@ int OCTET_STRING_fromBuf(OCTET_STRING_t *st, const char *str, int len) } OCTET_STRING_t *OCTET_STRING_new_fromBuf(asn_TYPE_descriptor_t *td, - const char *str, int len) + const char *str, int len) { asn_OCTET_STRING_specifics_t *specs = td->specifics ? (asn_OCTET_STRING_specifics_t *)td->specifics diff --git a/src/core/libs/supl/asn-rrlp/OCTET_STRING.h b/src/core/libs/supl/asn-rrlp/OCTET_STRING.h index 042fa5ab1..95b6a66f9 100644 --- a/src/core/libs/supl/asn-rrlp/OCTET_STRING.h +++ b/src/core/libs/supl/asn-rrlp/OCTET_STRING.h @@ -59,7 +59,7 @@ extern "C" * allocate empty OCTET STRING. */ OCTET_STRING_t *OCTET_STRING_new_fromBuf(asn_TYPE_descriptor_t *td, - const char *str, int size); + const char *str, int size); /**************************** * Internally useful stuff. * diff --git a/src/core/libs/supl/asn-rrlp/OTD-FirstSetMsrs.c b/src/core/libs/supl/asn-rrlp/OTD-FirstSetMsrs.c index 0c637e17e..52ebde10b 100644 --- a/src/core/libs/supl/asn-rrlp/OTD-FirstSetMsrs.c +++ b/src/core/libs/supl/asn-rrlp/OTD-FirstSetMsrs.c @@ -7,8 +7,8 @@ #include "OTD-FirstSetMsrs.h" int OTD_FirstSetMsrs_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { /* Replace with underlying type checker */ td->check_constraints = asn_DEF_OTD_MeasurementWithID.check_constraints; @@ -38,76 +38,76 @@ static void OTD_FirstSetMsrs_1_inherit_TYPE_descriptor( } void OTD_FirstSetMsrs_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { OTD_FirstSetMsrs_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int OTD_FirstSetMsrs_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, + void *app_key) { OTD_FirstSetMsrs_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t OTD_FirstSetMsrs_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { OTD_FirstSetMsrs_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t OTD_FirstSetMsrs_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { OTD_FirstSetMsrs_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t OTD_FirstSetMsrs_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { OTD_FirstSetMsrs_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t OTD_FirstSetMsrs_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { OTD_FirstSetMsrs_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t OTD_FirstSetMsrs_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { OTD_FirstSetMsrs_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t OTD_FirstSetMsrs_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { OTD_FirstSetMsrs_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); @@ -134,7 +134,7 @@ asn_TYPE_descriptor_t asn_DEF_OTD_FirstSetMsrs = { asn_DEF_OTD_FirstSetMsrs_tags_1, /* Same as above */ sizeof(asn_DEF_OTD_FirstSetMsrs_tags_1) / sizeof(asn_DEF_OTD_FirstSetMsrs_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ 0, 0, /* Defined elsewhere */ 0 /* No specifics */ diff --git a/src/core/libs/supl/asn-rrlp/OTD-MeasureInfo-5-Ext.c b/src/core/libs/supl/asn-rrlp/OTD-MeasureInfo-5-Ext.c index a785f145b..fb5916a4e 100644 --- a/src/core/libs/supl/asn-rrlp/OTD-MeasureInfo-5-Ext.c +++ b/src/core/libs/supl/asn-rrlp/OTD-MeasureInfo-5-Ext.c @@ -7,16 +7,16 @@ #include "OTD-MeasureInfo-5-Ext.h" int OTD_MeasureInfo_5_Ext_constraint(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { size_t size; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -31,7 +31,7 @@ int OTD_MeasureInfo_5_Ext_constraint(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -59,57 +59,57 @@ static void OTD_MeasureInfo_5_Ext_1_inherit_TYPE_descriptor( } void OTD_MeasureInfo_5_Ext_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { OTD_MeasureInfo_5_Ext_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int OTD_MeasureInfo_5_Ext_print(asn_TYPE_descriptor_t *td, - const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + const void *struct_ptr, int ilevel, + asn_app_consume_bytes_f *cb, void *app_key) { OTD_MeasureInfo_5_Ext_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t OTD_MeasureInfo_5_Ext_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, + const void *bufptr, size_t size, + int tag_mode) { OTD_MeasureInfo_5_Ext_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t OTD_MeasureInfo_5_Ext_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { OTD_MeasureInfo_5_Ext_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t OTD_MeasureInfo_5_Ext_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { OTD_MeasureInfo_5_Ext_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t OTD_MeasureInfo_5_Ext_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { OTD_MeasureInfo_5_Ext_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); @@ -122,7 +122,7 @@ asn_dec_rval_t OTD_MeasureInfo_5_Ext_decode_uper( { OTD_MeasureInfo_5_Ext_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t OTD_MeasureInfo_5_Ext_encode_uper( @@ -154,7 +154,7 @@ asn_TYPE_descriptor_t asn_DEF_OTD_MeasureInfo_5_Ext = { asn_DEF_OTD_MeasureInfo_5_Ext_tags_1, /* Same as above */ sizeof(asn_DEF_OTD_MeasureInfo_5_Ext_tags_1) / sizeof(asn_DEF_OTD_MeasureInfo_5_Ext_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ 0, 0, /* Defined elsewhere */ 0 /* No specifics */ diff --git a/src/core/libs/supl/asn-rrlp/OTD-MeasureInfo-R98-Ext.c b/src/core/libs/supl/asn-rrlp/OTD-MeasureInfo-R98-Ext.c index 70ac29bdc..ad6be88e1 100644 --- a/src/core/libs/supl/asn-rrlp/OTD-MeasureInfo-R98-Ext.c +++ b/src/core/libs/supl/asn-rrlp/OTD-MeasureInfo-R98-Ext.c @@ -8,18 +8,18 @@ static asn_TYPE_member_t asn_MBR_OTD_MeasureInfo_R98_Ext_1[] = { {ATF_NOFLAGS, 0, - offsetof(struct OTD_MeasureInfo_R98_Ext, otdMsrFirstSets_R98_Ext), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_OTD_MsrElementFirst_R98_Ext, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "otdMsrFirstSets-R98-Ext"}, + offsetof(struct OTD_MeasureInfo_R98_Ext, otdMsrFirstSets_R98_Ext), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_OTD_MsrElementFirst_R98_Ext, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "otdMsrFirstSets-R98-Ext"}, }; static ber_tlv_tag_t asn_DEF_OTD_MeasureInfo_R98_Ext_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_OTD_MeasureInfo_R98_Ext_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0} /* otdMsrFirstSets-R98-Ext at 974 */ + 0} /* otdMsrFirstSets-R98-Ext at 974 */ }; static asn_SEQUENCE_specifics_t asn_SPC_OTD_MeasureInfo_R98_Ext_specs_1 = { sizeof(struct OTD_MeasureInfo_R98_Ext), @@ -51,7 +51,7 @@ asn_TYPE_descriptor_t asn_DEF_OTD_MeasureInfo_R98_Ext = { asn_DEF_OTD_MeasureInfo_R98_Ext_tags_1, /* Same as above */ sizeof(asn_DEF_OTD_MeasureInfo_R98_Ext_tags_1) / sizeof(asn_DEF_OTD_MeasureInfo_R98_Ext_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_OTD_MeasureInfo_R98_Ext_1, 1, /* Elements count */ &asn_SPC_OTD_MeasureInfo_R98_Ext_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/OTD-MeasureInfo.c b/src/core/libs/supl/asn-rrlp/OTD-MeasureInfo.c index fd92230f4..a0069e3db 100644 --- a/src/core/libs/supl/asn-rrlp/OTD-MeasureInfo.c +++ b/src/core/libs/supl/asn-rrlp/OTD-MeasureInfo.c @@ -8,17 +8,17 @@ static asn_TYPE_member_t asn_MBR_OTD_MeasureInfo_1[] = { {ATF_NOFLAGS, 0, offsetof(struct OTD_MeasureInfo, otdMsrFirstSets), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_OTD_MsrElementFirst, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "otdMsrFirstSets"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_OTD_MsrElementFirst, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "otdMsrFirstSets"}, {ATF_POINTER, 1, offsetof(struct OTD_MeasureInfo, otdMsrRestSets), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfOTD_MsrElementRest, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "otdMsrRestSets"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfOTD_MsrElementRest, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "otdMsrRestSets"}, }; static int asn_MAP_OTD_MeasureInfo_oms_1[] = {1}; static ber_tlv_tag_t asn_DEF_OTD_MeasureInfo_tags_1[] = { @@ -57,7 +57,7 @@ asn_TYPE_descriptor_t asn_DEF_OTD_MeasureInfo = { asn_DEF_OTD_MeasureInfo_tags_1, /* Same as above */ sizeof(asn_DEF_OTD_MeasureInfo_tags_1) / sizeof(asn_DEF_OTD_MeasureInfo_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_OTD_MeasureInfo_1, 2, /* Elements count */ &asn_SPC_OTD_MeasureInfo_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/OTD-Measurement.c b/src/core/libs/supl/asn-rrlp/OTD-Measurement.c index 642f12138..676d89738 100644 --- a/src/core/libs/supl/asn-rrlp/OTD-Measurement.c +++ b/src/core/libs/supl/asn-rrlp/OTD-Measurement.c @@ -8,22 +8,22 @@ static asn_TYPE_member_t asn_MBR_OTD_Measurement_1[] = { {ATF_NOFLAGS, 0, offsetof(struct OTD_Measurement, nborTimeSlot), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_ModuloTimeSlot, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "nborTimeSlot"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_ModuloTimeSlot, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "nborTimeSlot"}, {ATF_NOFLAGS, 0, offsetof(struct OTD_Measurement, eotdQuality), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_EOTDQuality, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "eotdQuality"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_EOTDQuality, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "eotdQuality"}, {ATF_NOFLAGS, 0, offsetof(struct OTD_Measurement, otdValue), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_OTDValue, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "otdValue"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_OTDValue, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "otdValue"}, }; static ber_tlv_tag_t asn_DEF_OTD_Measurement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -62,7 +62,7 @@ asn_TYPE_descriptor_t asn_DEF_OTD_Measurement = { asn_DEF_OTD_Measurement_tags_1, /* Same as above */ sizeof(asn_DEF_OTD_Measurement_tags_1) / sizeof(asn_DEF_OTD_Measurement_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_OTD_Measurement_1, 3, /* Elements count */ &asn_SPC_OTD_Measurement_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/OTD-Measurement.h b/src/core/libs/supl/asn-rrlp/OTD-Measurement.h index f2f0492ad..8b3f82305 100644 --- a/src/core/libs/supl/asn-rrlp/OTD-Measurement.h +++ b/src/core/libs/supl/asn-rrlp/OTD-Measurement.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include "ModuloTimeSlot.h" #include "EOTDQuality.h" +#include "ModuloTimeSlot.h" #include "OTDValue.h" #include diff --git a/src/core/libs/supl/asn-rrlp/OTD-MeasurementWithID.c b/src/core/libs/supl/asn-rrlp/OTD-MeasurementWithID.c index 4da4bbef2..bd4193065 100644 --- a/src/core/libs/supl/asn-rrlp/OTD-MeasurementWithID.c +++ b/src/core/libs/supl/asn-rrlp/OTD-MeasurementWithID.c @@ -8,28 +8,28 @@ static asn_TYPE_member_t asn_MBR_OTD_MeasurementWithID_1[] = { {ATF_NOFLAGS, 0, offsetof(struct OTD_MeasurementWithID, neighborIdentity), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), +1, /* EXPLICIT tag at current level */ - &asn_DEF_NeighborIdentity, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "neighborIdentity"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), +1, /* EXPLICIT tag at current level */ + &asn_DEF_NeighborIdentity, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "neighborIdentity"}, {ATF_NOFLAGS, 0, offsetof(struct OTD_MeasurementWithID, nborTimeSlot), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_ModuloTimeSlot, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "nborTimeSlot"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_ModuloTimeSlot, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "nborTimeSlot"}, {ATF_NOFLAGS, 0, offsetof(struct OTD_MeasurementWithID, eotdQuality), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_EOTDQuality, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "eotdQuality"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_EOTDQuality, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "eotdQuality"}, {ATF_NOFLAGS, 0, offsetof(struct OTD_MeasurementWithID, otdValue), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_OTDValue, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "otdValue"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_OTDValue, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "otdValue"}, }; static ber_tlv_tag_t asn_DEF_OTD_MeasurementWithID_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -69,7 +69,7 @@ asn_TYPE_descriptor_t asn_DEF_OTD_MeasurementWithID = { asn_DEF_OTD_MeasurementWithID_tags_1, /* Same as above */ sizeof(asn_DEF_OTD_MeasurementWithID_tags_1) / sizeof(asn_DEF_OTD_MeasurementWithID_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_OTD_MeasurementWithID_1, 4, /* Elements count */ &asn_SPC_OTD_MeasurementWithID_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/OTD-MeasurementWithID.h b/src/core/libs/supl/asn-rrlp/OTD-MeasurementWithID.h index 6d57f1fef..8c8d13414 100644 --- a/src/core/libs/supl/asn-rrlp/OTD-MeasurementWithID.h +++ b/src/core/libs/supl/asn-rrlp/OTD-MeasurementWithID.h @@ -10,9 +10,9 @@ #include /* Including external dependencies */ -#include "NeighborIdentity.h" -#include "ModuloTimeSlot.h" #include "EOTDQuality.h" +#include "ModuloTimeSlot.h" +#include "NeighborIdentity.h" #include "OTDValue.h" #include diff --git a/src/core/libs/supl/asn-rrlp/OTD-MsrElementFirst-R98-Ext.c b/src/core/libs/supl/asn-rrlp/OTD-MsrElementFirst-R98-Ext.c index 026d37a7f..b9768f2c6 100644 --- a/src/core/libs/supl/asn-rrlp/OTD-MsrElementFirst-R98-Ext.c +++ b/src/core/libs/supl/asn-rrlp/OTD-MsrElementFirst-R98-Ext.c @@ -8,19 +8,19 @@ static asn_TYPE_member_t asn_MBR_OTD_MsrElementFirst_R98_Ext_1[] = { {ATF_POINTER, 1, - offsetof(struct OTD_MsrElementFirst_R98_Ext, otd_FirstSetMsrs_R98_Ext), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfOTD_FirstSetMsrs_R98_Ext, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "otd-FirstSetMsrs-R98-Ext"}, + offsetof(struct OTD_MsrElementFirst_R98_Ext, otd_FirstSetMsrs_R98_Ext), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfOTD_FirstSetMsrs_R98_Ext, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "otd-FirstSetMsrs-R98-Ext"}, }; static int asn_MAP_OTD_MsrElementFirst_R98_Ext_oms_1[] = {0}; static ber_tlv_tag_t asn_DEF_OTD_MsrElementFirst_R98_Ext_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_OTD_MsrElementFirst_R98_Ext_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0} /* otd-FirstSetMsrs-R98-Ext at 979 */ + 0} /* otd-FirstSetMsrs-R98-Ext at 979 */ }; static asn_SEQUENCE_specifics_t asn_SPC_OTD_MsrElementFirst_R98_Ext_specs_1 = { sizeof(struct OTD_MsrElementFirst_R98_Ext), @@ -49,10 +49,10 @@ asn_TYPE_descriptor_t asn_DEF_OTD_MsrElementFirst_R98_Ext = { asn_DEF_OTD_MsrElementFirst_R98_Ext_tags_1, sizeof(asn_DEF_OTD_MsrElementFirst_R98_Ext_tags_1) / sizeof(asn_DEF_OTD_MsrElementFirst_R98_Ext_tags_1[0]), /* 1 */ - asn_DEF_OTD_MsrElementFirst_R98_Ext_tags_1, /* Same as above */ + asn_DEF_OTD_MsrElementFirst_R98_Ext_tags_1, /* Same as above */ sizeof(asn_DEF_OTD_MsrElementFirst_R98_Ext_tags_1) / sizeof(asn_DEF_OTD_MsrElementFirst_R98_Ext_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_OTD_MsrElementFirst_R98_Ext_1, 1, /* Elements count */ &asn_SPC_OTD_MsrElementFirst_R98_Ext_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/OTD-MsrElementFirst.c b/src/core/libs/supl/asn-rrlp/OTD-MsrElementFirst.c index 9a2c1902e..03bc06c4c 100644 --- a/src/core/libs/supl/asn-rrlp/OTD-MsrElementFirst.c +++ b/src/core/libs/supl/asn-rrlp/OTD-MsrElementFirst.c @@ -15,7 +15,7 @@ static int memb_refFrameNumber_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,22 +29,22 @@ static int memb_refFrameNumber_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_taCorrection_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -58,7 +58,7 @@ static int memb_taCorrection_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -77,37 +77,37 @@ static asn_per_constraints_t ASN_PER_MEMB_TA_CORRECTION_CONSTR_6 = { }; static asn_TYPE_member_t asn_MBR_OTD_MsrElementFirst_1[] = { {ATF_NOFLAGS, 0, offsetof(struct OTD_MsrElementFirst, refFrameNumber), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_refFrameNumber_constraint_1, - &ASN_PER_MEMB_REF_FRAME_NUMBER_CONSTR_2, 0, "refFrameNumber"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_refFrameNumber_constraint_1, + &ASN_PER_MEMB_REF_FRAME_NUMBER_CONSTR_2, 0, "refFrameNumber"}, {ATF_NOFLAGS, 0, offsetof(struct OTD_MsrElementFirst, referenceTimeSlot), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_ModuloTimeSlot, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "referenceTimeSlot"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_ModuloTimeSlot, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "referenceTimeSlot"}, {ATF_POINTER, 1, offsetof(struct OTD_MsrElementFirst, toaMeasurementsOfRef), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_TOA_MeasurementsOfRef, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "toaMeasurementsOfRef"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_TOA_MeasurementsOfRef, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "toaMeasurementsOfRef"}, {ATF_NOFLAGS, 0, offsetof(struct OTD_MsrElementFirst, stdResolution), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_StdResolution, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "stdResolution"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_StdResolution, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "stdResolution"}, {ATF_POINTER, 2, offsetof(struct OTD_MsrElementFirst, taCorrection), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_taCorrection_constraint_1, - &ASN_PER_MEMB_TA_CORRECTION_CONSTR_6, 0, "taCorrection"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_taCorrection_constraint_1, + &ASN_PER_MEMB_TA_CORRECTION_CONSTR_6, 0, "taCorrection"}, {ATF_POINTER, 1, offsetof(struct OTD_MsrElementFirst, otd_FirstSetMsrs), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfOTD_FirstSetMsrs, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "otd-FirstSetMsrs"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfOTD_FirstSetMsrs, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "otd-FirstSetMsrs"}, }; static int asn_MAP_OTD_MsrElementFirst_oms_1[] = {2, 4, 5}; static ber_tlv_tag_t asn_DEF_OTD_MsrElementFirst_tags_1[] = { @@ -115,9 +115,9 @@ static ber_tlv_tag_t asn_DEF_OTD_MsrElementFirst_tags_1[] = { static asn_TYPE_tag2member_t asn_MAP_OTD_MsrElementFirst_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* refFrameNumber at 334 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0}, /* referenceTimeSlot at 335 */ + 0}, /* referenceTimeSlot at 335 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, - 0}, /* toaMeasurementsOfRef at 336 */ + 0}, /* toaMeasurementsOfRef at 336 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, 0}, /* stdResolution at 337 */ {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, 0}, /* taCorrection at 338 */ {(ASN_TAG_CLASS_CONTEXT | (5 << 2)), 5, 0, 0} /* otd-FirstSetMsrs at 341 */ @@ -152,7 +152,7 @@ asn_TYPE_descriptor_t asn_DEF_OTD_MsrElementFirst = { asn_DEF_OTD_MsrElementFirst_tags_1, /* Same as above */ sizeof(asn_DEF_OTD_MsrElementFirst_tags_1) / sizeof(asn_DEF_OTD_MsrElementFirst_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_OTD_MsrElementFirst_1, 6, /* Elements count */ &asn_SPC_OTD_MsrElementFirst_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/OTD-MsrElementFirst.h b/src/core/libs/supl/asn-rrlp/OTD-MsrElementFirst.h index 39afa7bd5..f63179565 100644 --- a/src/core/libs/supl/asn-rrlp/OTD-MsrElementFirst.h +++ b/src/core/libs/supl/asn-rrlp/OTD-MsrElementFirst.h @@ -10,9 +10,9 @@ #include /* Including external dependencies */ -#include #include "ModuloTimeSlot.h" #include "StdResolution.h" +#include #include #ifdef __cplusplus @@ -46,8 +46,8 @@ extern "C" #endif /* Referred external types */ -#include "TOA-MeasurementsOfRef.h" #include "SeqOfOTD-FirstSetMsrs.h" +#include "TOA-MeasurementsOfRef.h" #endif /* _OTD_MsrElementFirst_H_ */ #include diff --git a/src/core/libs/supl/asn-rrlp/OTD-MsrElementRest.c b/src/core/libs/supl/asn-rrlp/OTD-MsrElementRest.c index 7f6f47685..f868dbcde 100644 --- a/src/core/libs/supl/asn-rrlp/OTD-MsrElementRest.c +++ b/src/core/libs/supl/asn-rrlp/OTD-MsrElementRest.c @@ -15,7 +15,7 @@ static int memb_refFrameNumber_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,22 +29,22 @@ static int memb_refFrameNumber_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_taCorrection_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -58,7 +58,7 @@ static int memb_taCorrection_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -77,37 +77,37 @@ static asn_per_constraints_t ASN_PER_MEMB_TA_CORRECTION_CONSTR_6 = { }; static asn_TYPE_member_t asn_MBR_OTD_MsrElementRest_1[] = { {ATF_NOFLAGS, 0, offsetof(struct OTD_MsrElementRest, refFrameNumber), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_refFrameNumber_constraint_1, - &ASN_PER_MEMB_REF_FRAME_NUMBER_CONSTR_2, 0, "refFrameNumber"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_refFrameNumber_constraint_1, + &ASN_PER_MEMB_REF_FRAME_NUMBER_CONSTR_2, 0, "refFrameNumber"}, {ATF_NOFLAGS, 0, offsetof(struct OTD_MsrElementRest, referenceTimeSlot), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_ModuloTimeSlot, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "referenceTimeSlot"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_ModuloTimeSlot, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "referenceTimeSlot"}, {ATF_POINTER, 1, offsetof(struct OTD_MsrElementRest, toaMeasurementsOfRef), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_TOA_MeasurementsOfRef, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "toaMeasurementsOfRef"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_TOA_MeasurementsOfRef, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "toaMeasurementsOfRef"}, {ATF_NOFLAGS, 0, offsetof(struct OTD_MsrElementRest, stdResolution), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_StdResolution, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "stdResolution"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_StdResolution, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "stdResolution"}, {ATF_POINTER, 2, offsetof(struct OTD_MsrElementRest, taCorrection), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_taCorrection_constraint_1, - &ASN_PER_MEMB_TA_CORRECTION_CONSTR_6, 0, "taCorrection"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_taCorrection_constraint_1, + &ASN_PER_MEMB_TA_CORRECTION_CONSTR_6, 0, "taCorrection"}, {ATF_POINTER, 1, offsetof(struct OTD_MsrElementRest, otd_MsrsOfOtherSets), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfOTD_MsrsOfOtherSets, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "otd-MsrsOfOtherSets"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfOTD_MsrsOfOtherSets, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "otd-MsrsOfOtherSets"}, }; static int asn_MAP_OTD_MsrElementRest_oms_1[] = {2, 4, 5}; static ber_tlv_tag_t asn_DEF_OTD_MsrElementRest_tags_1[] = { @@ -115,13 +115,13 @@ static ber_tlv_tag_t asn_DEF_OTD_MsrElementRest_tags_1[] = { static asn_TYPE_tag2member_t asn_MAP_OTD_MsrElementRest_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* refFrameNumber at 347 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0}, /* referenceTimeSlot at 348 */ + 0}, /* referenceTimeSlot at 348 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, - 0}, /* toaMeasurementsOfRef at 349 */ + 0}, /* toaMeasurementsOfRef at 349 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, 0}, /* stdResolution at 350 */ {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, 0}, /* taCorrection at 351 */ {(ASN_TAG_CLASS_CONTEXT | (5 << 2)), 5, 0, - 0} /* otd-MsrsOfOtherSets at 354 */ + 0} /* otd-MsrsOfOtherSets at 354 */ }; static asn_SEQUENCE_specifics_t asn_SPC_OTD_MsrElementRest_specs_1 = { sizeof(struct OTD_MsrElementRest), @@ -153,7 +153,7 @@ asn_TYPE_descriptor_t asn_DEF_OTD_MsrElementRest = { asn_DEF_OTD_MsrElementRest_tags_1, /* Same as above */ sizeof(asn_DEF_OTD_MsrElementRest_tags_1) / sizeof(asn_DEF_OTD_MsrElementRest_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_OTD_MsrElementRest_1, 6, /* Elements count */ &asn_SPC_OTD_MsrElementRest_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/OTD-MsrElementRest.h b/src/core/libs/supl/asn-rrlp/OTD-MsrElementRest.h index 3287ccf96..6df64e30e 100644 --- a/src/core/libs/supl/asn-rrlp/OTD-MsrElementRest.h +++ b/src/core/libs/supl/asn-rrlp/OTD-MsrElementRest.h @@ -10,9 +10,9 @@ #include /* Including external dependencies */ -#include #include "ModuloTimeSlot.h" #include "StdResolution.h" +#include #include #ifdef __cplusplus @@ -46,8 +46,8 @@ extern "C" #endif /* Referred external types */ -#include "TOA-MeasurementsOfRef.h" #include "SeqOfOTD-MsrsOfOtherSets.h" +#include "TOA-MeasurementsOfRef.h" #endif /* _OTD_MsrElementRest_H_ */ #include diff --git a/src/core/libs/supl/asn-rrlp/OTD-MsrsOfOtherSets.c b/src/core/libs/supl/asn-rrlp/OTD-MsrsOfOtherSets.c index 9f3d01df9..71d0ae0fd 100644 --- a/src/core/libs/supl/asn-rrlp/OTD-MsrsOfOtherSets.c +++ b/src/core/libs/supl/asn-rrlp/OTD-MsrsOfOtherSets.c @@ -14,23 +14,23 @@ static asn_per_constraints_t ASN_PER_TYPE_OTD_MSRS_OF_OTHER_SETS_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_OTD_MsrsOfOtherSets_1[] = { {ATF_NOFLAGS, 0, - offsetof(struct OTD_MsrsOfOtherSets, choice.identityNotPresent), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_OTD_Measurement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "identityNotPresent"}, + offsetof(struct OTD_MsrsOfOtherSets, choice.identityNotPresent), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_OTD_Measurement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "identityNotPresent"}, {ATF_NOFLAGS, 0, - offsetof(struct OTD_MsrsOfOtherSets, choice.identityPresent), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_OTD_MeasurementWithID, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "identityPresent"}, + offsetof(struct OTD_MsrsOfOtherSets, choice.identityPresent), + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_OTD_MeasurementWithID, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "identityPresent"}, }; static asn_TYPE_tag2member_t asn_MAP_OTD_MsrsOfOtherSets_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0}, /* identityNotPresent at 372 */ + 0}, /* identityNotPresent at 372 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0} /* identityPresent at 374 */ }; static asn_CHOICE_specifics_t asn_SPC_OTD_MsrsOfOtherSets_specs_1 = { diff --git a/src/core/libs/supl/asn-rrlp/OTDValue.c b/src/core/libs/supl/asn-rrlp/OTDValue.c index 0a51c64a6..cfff75410 100644 --- a/src/core/libs/supl/asn-rrlp/OTDValue.c +++ b/src/core/libs/supl/asn-rrlp/OTDValue.c @@ -7,14 +7,14 @@ #include "OTDValue.h" int OTDValue_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int OTDValue_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -55,68 +55,68 @@ static void OTDValue_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void OTDValue_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { OTDValue_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int OTDValue_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { OTDValue_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t OTDValue_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, + int tag_mode) { OTDValue_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t OTDValue_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { OTDValue_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t OTDValue_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { OTDValue_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t OTDValue_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { OTDValue_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t OTDValue_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { OTDValue_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t OTDValue_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { OTDValue_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/PDU.c b/src/core/libs/supl/asn-rrlp/PDU.c index 71249ab0c..f4a9485c0 100644 --- a/src/core/libs/supl/asn-rrlp/PDU.c +++ b/src/core/libs/supl/asn-rrlp/PDU.c @@ -15,7 +15,7 @@ static int memb_referenceNumber_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ static int memb_referenceNumber_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -42,15 +42,15 @@ static asn_per_constraints_t ASN_PER_MEMB_REFERENCE_NUMBER_CONSTR_2 = { }; static asn_TYPE_member_t asn_MBR_PDU_1[] = { {ATF_NOFLAGS, 0, offsetof(struct PDU, referenceNumber), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_referenceNumber_constraint_1, - &ASN_PER_MEMB_REFERENCE_NUMBER_CONSTR_2, 0, "referenceNumber"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_referenceNumber_constraint_1, + &ASN_PER_MEMB_REFERENCE_NUMBER_CONSTR_2, 0, "referenceNumber"}, {ATF_NOFLAGS, 0, offsetof(struct PDU, component), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), +1, /* EXPLICIT tag at current level */ - &asn_DEF_RRLP_Component, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "component"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), +1, /* EXPLICIT tag at current level */ + &asn_DEF_RRLP_Component, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "component"}, }; static ber_tlv_tag_t asn_DEF_PDU_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -84,9 +84,9 @@ asn_TYPE_descriptor_t asn_DEF_PDU = { 0, /* Use generic outmost tag fetcher */ asn_DEF_PDU_tags_1, sizeof(asn_DEF_PDU_tags_1) / sizeof(asn_DEF_PDU_tags_1[0]), /* 1 */ - asn_DEF_PDU_tags_1, /* Same as above */ + asn_DEF_PDU_tags_1, /* Same as above */ sizeof(asn_DEF_PDU_tags_1) / sizeof(asn_DEF_PDU_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_PDU_1, 2, /* Elements count */ &asn_SPC_PDU_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/PDU.h b/src/core/libs/supl/asn-rrlp/PDU.h index ba9a3085d..f108b6319 100644 --- a/src/core/libs/supl/asn-rrlp/PDU.h +++ b/src/core/libs/supl/asn-rrlp/PDU.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include #include "RRLP-Component.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/PositionData.c b/src/core/libs/supl/asn-rrlp/PositionData.c index cbfe07429..2e238dc4f 100644 --- a/src/core/libs/supl/asn-rrlp/PositionData.c +++ b/src/core/libs/supl/asn-rrlp/PositionData.c @@ -7,8 +7,8 @@ #include "PositionData.h" int PositionData_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const BIT_STRING_t *st = (const BIT_STRING_t *)sptr; size_t size; @@ -16,7 +16,7 @@ int PositionData_constraint(asn_TYPE_descriptor_t *td, const void *sptr, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -38,7 +38,7 @@ int PositionData_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -65,74 +65,74 @@ static void PositionData_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void PositionData_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { PositionData_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int PositionData_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { PositionData_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t PositionData_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { PositionData_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t PositionData_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { PositionData_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t PositionData_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, const char *opt_mname, + const void *bufptr, size_t size) { PositionData_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t PositionData_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { PositionData_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t PositionData_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { PositionData_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t PositionData_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { PositionData_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/PositionInstruct.c b/src/core/libs/supl/asn-rrlp/PositionInstruct.c index 58a0205f1..9edec5043 100644 --- a/src/core/libs/supl/asn-rrlp/PositionInstruct.c +++ b/src/core/libs/supl/asn-rrlp/PositionInstruct.c @@ -8,34 +8,34 @@ static asn_TYPE_member_t asn_MBR_PositionInstruct_1[] = { {ATF_NOFLAGS, 0, offsetof(struct PositionInstruct, methodType), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), +1, /* EXPLICIT tag at current level */ - &asn_DEF_MethodType, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "methodType"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), +1, /* EXPLICIT tag at current level */ + &asn_DEF_MethodType, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "methodType"}, {ATF_NOFLAGS, 0, offsetof(struct PositionInstruct, positionMethod), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_PositionMethod, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "positionMethod"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_PositionMethod, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "positionMethod"}, {ATF_NOFLAGS, 0, offsetof(struct PositionInstruct, measureResponseTime), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_MeasureResponseTime, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "measureResponseTime"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_MeasureResponseTime, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "measureResponseTime"}, {ATF_NOFLAGS, 0, offsetof(struct PositionInstruct, useMultipleSets), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_UseMultipleSets, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "useMultipleSets"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_UseMultipleSets, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "useMultipleSets"}, {ATF_POINTER, 1, offsetof(struct PositionInstruct, environmentCharacter), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_EnvironmentCharacter, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "environmentCharacter"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_EnvironmentCharacter, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "environmentCharacter"}, }; static int asn_MAP_PositionInstruct_oms_1[] = {4}; static ber_tlv_tag_t asn_DEF_PositionInstruct_tags_1[] = { @@ -44,10 +44,10 @@ static asn_TYPE_tag2member_t asn_MAP_PositionInstruct_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* methodType at 108 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0}, /* positionMethod at 109 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, - 0}, /* measureResponseTime at 110 */ + 0}, /* measureResponseTime at 110 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, 0}, /* useMultipleSets at 111 */ {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, - 0} /* environmentCharacter at 112 */ + 0} /* environmentCharacter at 112 */ }; static asn_SEQUENCE_specifics_t asn_SPC_PositionInstruct_specs_1 = { sizeof(struct PositionInstruct), @@ -79,7 +79,7 @@ asn_TYPE_descriptor_t asn_DEF_PositionInstruct = { asn_DEF_PositionInstruct_tags_1, /* Same as above */ sizeof(asn_DEF_PositionInstruct_tags_1) / sizeof(asn_DEF_PositionInstruct_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_PositionInstruct_1, 5, /* Elements count */ &asn_SPC_PositionInstruct_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/PositionInstruct.h b/src/core/libs/supl/asn-rrlp/PositionInstruct.h index 1043f1fe6..164e27086 100644 --- a/src/core/libs/supl/asn-rrlp/PositionInstruct.h +++ b/src/core/libs/supl/asn-rrlp/PositionInstruct.h @@ -10,11 +10,11 @@ #include /* Including external dependencies */ +#include "EnvironmentCharacter.h" +#include "MeasureResponseTime.h" #include "MethodType.h" #include "PositionMethod.h" -#include "MeasureResponseTime.h" #include "UseMultipleSets.h" -#include "EnvironmentCharacter.h" #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/PositionMethod.c b/src/core/libs/supl/asn-rrlp/PositionMethod.c index 537d2f801..5bcd8629b 100644 --- a/src/core/libs/supl/asn-rrlp/PositionMethod.c +++ b/src/core/libs/supl/asn-rrlp/PositionMethod.c @@ -7,8 +7,8 @@ #include "PositionMethod.h" int PositionMethod_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { /* Replace with underlying type checker */ td->check_constraints = asn_DEF_ENUMERATED.check_constraints; @@ -39,75 +39,75 @@ static void PositionMethod_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void PositionMethod_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { PositionMethod_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int PositionMethod_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { PositionMethod_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t PositionMethod_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { PositionMethod_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t PositionMethod_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { PositionMethod_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t PositionMethod_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { PositionMethod_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t PositionMethod_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { PositionMethod_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t PositionMethod_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { PositionMethod_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t PositionMethod_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { PositionMethod_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/ProtocolError.c b/src/core/libs/supl/asn-rrlp/ProtocolError.c index 5516db6fc..decb12c8e 100644 --- a/src/core/libs/supl/asn-rrlp/ProtocolError.c +++ b/src/core/libs/supl/asn-rrlp/ProtocolError.c @@ -8,23 +8,23 @@ static asn_TYPE_member_t asn_MBR_ProtocolError_1[] = { {ATF_NOFLAGS, 0, offsetof(struct ProtocolError, errorCause), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_ErrorCodes, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "errorCause"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_ErrorCodes, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "errorCause"}, {ATF_POINTER, 2, offsetof(struct ProtocolError, extensionContainer), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_ExtensionContainer, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "extensionContainer"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_ExtensionContainer, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "extensionContainer"}, {ATF_POINTER, 1, - offsetof(struct ProtocolError, rel_5_ProtocolError_Extension), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Rel_5_ProtocolError_Extension, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "rel-5-ProtocolError-Extension"}, + offsetof(struct ProtocolError, rel_5_ProtocolError_Extension), + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Rel_5_ProtocolError_Extension, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "rel-5-ProtocolError-Extension"}, }; static int asn_MAP_ProtocolError_oms_1[] = {1, 2}; static ber_tlv_tag_t asn_DEF_ProtocolError_tags_1[] = { @@ -32,9 +32,9 @@ static ber_tlv_tag_t asn_DEF_ProtocolError_tags_1[] = { static asn_TYPE_tag2member_t asn_MAP_ProtocolError_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* errorCause at 96 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0}, /* extensionContainer at 97 */ + 0}, /* extensionContainer at 97 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, - 0} /* rel-5-ProtocolError-Extension at 100 */ + 0} /* rel-5-ProtocolError-Extension at 100 */ }; static asn_SEQUENCE_specifics_t asn_SPC_ProtocolError_specs_1 = { sizeof(struct ProtocolError), @@ -66,7 +66,7 @@ asn_TYPE_descriptor_t asn_DEF_ProtocolError = { asn_DEF_ProtocolError_tags_1, /* Same as above */ sizeof(asn_DEF_ProtocolError_tags_1) / sizeof(asn_DEF_ProtocolError_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_ProtocolError_1, 3, /* Elements count */ &asn_SPC_ProtocolError_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/RRLP-Component.c b/src/core/libs/supl/asn-rrlp/RRLP-Component.c index 93cd43550..af05883c4 100644 --- a/src/core/libs/supl/asn-rrlp/RRLP-Component.c +++ b/src/core/libs/supl/asn-rrlp/RRLP-Component.c @@ -14,34 +14,34 @@ static asn_per_constraints_t ASN_PER_TYPE_RRLP_COMPONENT_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_RRLP_Component_1[] = { {ATF_NOFLAGS, 0, offsetof(struct RRLP_Component, choice.msrPositionReq), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_MsrPosition_Req, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "msrPositionReq"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_MsrPosition_Req, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "msrPositionReq"}, {ATF_NOFLAGS, 0, offsetof(struct RRLP_Component, choice.msrPositionRsp), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_MsrPosition_Rsp, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "msrPositionRsp"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_MsrPosition_Rsp, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "msrPositionRsp"}, {ATF_NOFLAGS, 0, offsetof(struct RRLP_Component, choice.assistanceData), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_AssistanceData, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "assistanceData"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_AssistanceData, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "assistanceData"}, {ATF_NOFLAGS, 0, offsetof(struct RRLP_Component, choice.assistanceDataAck), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NULL, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "assistanceDataAck"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NULL, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "assistanceDataAck"}, {ATF_NOFLAGS, 0, offsetof(struct RRLP_Component, choice.protocolError), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_ProtocolError, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "protocolError"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_ProtocolError, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "protocolError"}, }; static asn_TYPE_tag2member_t asn_MAP_RRLP_Component_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* msrPositionReq at 21 */ diff --git a/src/core/libs/supl/asn-rrlp/RRLP-Component.h b/src/core/libs/supl/asn-rrlp/RRLP-Component.h index 48d2e0f51..8198f7cb7 100644 --- a/src/core/libs/supl/asn-rrlp/RRLP-Component.h +++ b/src/core/libs/supl/asn-rrlp/RRLP-Component.h @@ -10,11 +10,11 @@ #include /* Including external dependencies */ +#include "AssistanceData.h" #include "MsrPosition-Req.h" #include "MsrPosition-Rsp.h" -#include "AssistanceData.h" -#include #include "ProtocolError.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/RefLocation.c b/src/core/libs/supl/asn-rrlp/RefLocation.c index efc9c4ca0..9b11136d9 100644 --- a/src/core/libs/supl/asn-rrlp/RefLocation.c +++ b/src/core/libs/supl/asn-rrlp/RefLocation.c @@ -8,11 +8,11 @@ static asn_TYPE_member_t asn_MBR_RefLocation_1[] = { {ATF_NOFLAGS, 0, offsetof(struct RefLocation, threeDLocation), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Ext_GeographicalInformation, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "threeDLocation"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Ext_GeographicalInformation, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "threeDLocation"}, }; static ber_tlv_tag_t asn_DEF_RefLocation_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/RefQuality.c b/src/core/libs/supl/asn-rrlp/RefQuality.c index e2e7c62b0..224d35f94 100644 --- a/src/core/libs/supl/asn-rrlp/RefQuality.c +++ b/src/core/libs/supl/asn-rrlp/RefQuality.c @@ -7,14 +7,14 @@ #include "RefQuality.h" int RefQuality_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int RefQuality_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -55,69 +55,69 @@ static void RefQuality_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void RefQuality_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { RefQuality_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int RefQuality_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { RefQuality_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t RefQuality_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { RefQuality_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t RefQuality_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { RefQuality_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t RefQuality_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, const char *opt_mname, + const void *bufptr, size_t size) { RefQuality_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t RefQuality_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { RefQuality_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t RefQuality_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { RefQuality_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t RefQuality_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { RefQuality_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/ReferenceAssistData.c b/src/core/libs/supl/asn-rrlp/ReferenceAssistData.c index ec800df72..2ef834aac 100644 --- a/src/core/libs/supl/asn-rrlp/ReferenceAssistData.c +++ b/src/core/libs/supl/asn-rrlp/ReferenceAssistData.c @@ -8,28 +8,28 @@ static asn_TYPE_member_t asn_MBR_ReferenceAssistData_1[] = { {ATF_NOFLAGS, 0, offsetof(struct ReferenceAssistData, bcchCarrier), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BCCHCarrier, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "bcchCarrier"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BCCHCarrier, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "bcchCarrier"}, {ATF_NOFLAGS, 0, offsetof(struct ReferenceAssistData, bsic), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BSIC, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "bsic"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BSIC, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "bsic"}, {ATF_NOFLAGS, 0, offsetof(struct ReferenceAssistData, timeSlotScheme), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_TimeSlotScheme, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "timeSlotScheme"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_TimeSlotScheme, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "timeSlotScheme"}, {ATF_POINTER, 1, offsetof(struct ReferenceAssistData, btsPosition), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BTSPosition, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "btsPosition"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BTSPosition, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "btsPosition"}, }; static int asn_MAP_ReferenceAssistData_oms_1[] = {3}; static ber_tlv_tag_t asn_DEF_ReferenceAssistData_tags_1[] = { @@ -70,7 +70,7 @@ asn_TYPE_descriptor_t asn_DEF_ReferenceAssistData = { asn_DEF_ReferenceAssistData_tags_1, /* Same as above */ sizeof(asn_DEF_ReferenceAssistData_tags_1) / sizeof(asn_DEF_ReferenceAssistData_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_ReferenceAssistData_1, 4, /* Elements count */ &asn_SPC_ReferenceAssistData_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/ReferenceAssistData.h b/src/core/libs/supl/asn-rrlp/ReferenceAssistData.h index 0ae8e55e1..acd86164d 100644 --- a/src/core/libs/supl/asn-rrlp/ReferenceAssistData.h +++ b/src/core/libs/supl/asn-rrlp/ReferenceAssistData.h @@ -12,8 +12,8 @@ /* Including external dependencies */ #include "BCCHCarrier.h" #include "BSIC.h" -#include "TimeSlotScheme.h" #include "BTSPosition.h" +#include "TimeSlotScheme.h" #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/ReferenceFrame.c b/src/core/libs/supl/asn-rrlp/ReferenceFrame.c index c87e89dd0..11a1eaeeb 100644 --- a/src/core/libs/supl/asn-rrlp/ReferenceFrame.c +++ b/src/core/libs/supl/asn-rrlp/ReferenceFrame.c @@ -7,16 +7,16 @@ #include "ReferenceFrame.h" static int memb_referenceFN_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,7 +30,7 @@ static int memb_referenceFN_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -44,7 +44,7 @@ static int memb_referenceFNMSB_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -58,7 +58,7 @@ static int memb_referenceFNMSB_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -77,13 +77,13 @@ static asn_per_constraints_t ASN_PER_MEMB_REFERENCE_FNMSB_CONSTR_3 = { }; static asn_TYPE_member_t asn_MBR_ReferenceFrame_1[] = { {ATF_NOFLAGS, 0, offsetof(struct ReferenceFrame, referenceFN), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_referenceFN_constraint_1, - &ASN_PER_MEMB_REFERENCE_FN_CONSTR_2, 0, "referenceFN"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_referenceFN_constraint_1, + &ASN_PER_MEMB_REFERENCE_FN_CONSTR_2, 0, "referenceFN"}, {ATF_POINTER, 1, offsetof(struct ReferenceFrame, referenceFNMSB), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_referenceFNMSB_constraint_1, - &ASN_PER_MEMB_REFERENCE_FNMSB_CONSTR_3, 0, "referenceFNMSB"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_referenceFNMSB_constraint_1, + &ASN_PER_MEMB_REFERENCE_FNMSB_CONSTR_3, 0, "referenceFNMSB"}, }; static int asn_MAP_ReferenceFrame_oms_1[] = {1}; static ber_tlv_tag_t asn_DEF_ReferenceFrame_tags_1[] = { @@ -122,7 +122,7 @@ asn_TYPE_descriptor_t asn_DEF_ReferenceFrame = { asn_DEF_ReferenceFrame_tags_1, /* Same as above */ sizeof(asn_DEF_ReferenceFrame_tags_1) / sizeof(asn_DEF_ReferenceFrame_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_ReferenceFrame_1, 2, /* Elements count */ &asn_SPC_ReferenceFrame_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/ReferenceIdentity.c b/src/core/libs/supl/asn-rrlp/ReferenceIdentity.c index 1f5c212ff..3f388d3ae 100644 --- a/src/core/libs/supl/asn-rrlp/ReferenceIdentity.c +++ b/src/core/libs/supl/asn-rrlp/ReferenceIdentity.c @@ -8,11 +8,11 @@ static asn_TYPE_member_t asn_MBR_ReferenceIdentity_1[] = { {ATF_NOFLAGS, 0, offsetof(struct ReferenceIdentity, refBTSList), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfReferenceIdentityType, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "refBTSList"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfReferenceIdentityType, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "refBTSList"}, }; static ber_tlv_tag_t asn_DEF_ReferenceIdentity_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -49,7 +49,7 @@ asn_TYPE_descriptor_t asn_DEF_ReferenceIdentity = { asn_DEF_ReferenceIdentity_tags_1, /* Same as above */ sizeof(asn_DEF_ReferenceIdentity_tags_1) / sizeof(asn_DEF_ReferenceIdentity_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_ReferenceIdentity_1, 1, /* Elements count */ &asn_SPC_ReferenceIdentity_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/ReferenceIdentityType.c b/src/core/libs/supl/asn-rrlp/ReferenceIdentityType.c index c749f97d5..7497c61df 100644 --- a/src/core/libs/supl/asn-rrlp/ReferenceIdentityType.c +++ b/src/core/libs/supl/asn-rrlp/ReferenceIdentityType.c @@ -14,37 +14,37 @@ static asn_per_constraints_t ASN_PER_TYPE_REFERENCE_IDENTITY_TYPE_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_ReferenceIdentityType_1[] = { {ATF_NOFLAGS, 0, - offsetof(struct ReferenceIdentityType, choice.bsicAndCarrier), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BSICAndCarrier, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "bsicAndCarrier"}, + offsetof(struct ReferenceIdentityType, choice.bsicAndCarrier), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BSICAndCarrier, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "bsicAndCarrier"}, {ATF_NOFLAGS, 0, offsetof(struct ReferenceIdentityType, choice.ci), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_CellID, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ci"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_CellID, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ci"}, {ATF_NOFLAGS, 0, - offsetof(struct ReferenceIdentityType, choice.requestIndex), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_RequestIndex, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "requestIndex"}, + offsetof(struct ReferenceIdentityType, choice.requestIndex), + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_RequestIndex, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "requestIndex"}, {ATF_NOFLAGS, 0, - offsetof(struct ReferenceIdentityType, choice.systemInfoIndex), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SystemInfoIndex, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "systemInfoIndex"}, + offsetof(struct ReferenceIdentityType, choice.systemInfoIndex), + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SystemInfoIndex, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "systemInfoIndex"}, {ATF_NOFLAGS, 0, offsetof(struct ReferenceIdentityType, choice.ciAndLAC), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_CellIDAndLAC, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ciAndLAC"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_CellIDAndLAC, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ciAndLAC"}, }; static asn_TYPE_tag2member_t asn_MAP_ReferenceIdentityType_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* bsicAndCarrier at 294 */ diff --git a/src/core/libs/supl/asn-rrlp/ReferenceIdentityType.h b/src/core/libs/supl/asn-rrlp/ReferenceIdentityType.h index 2fd9d6ae1..a4852f010 100644 --- a/src/core/libs/supl/asn-rrlp/ReferenceIdentityType.h +++ b/src/core/libs/supl/asn-rrlp/ReferenceIdentityType.h @@ -12,9 +12,9 @@ /* Including external dependencies */ #include "BSICAndCarrier.h" #include "CellID.h" +#include "CellIDAndLAC.h" #include "RequestIndex.h" #include "SystemInfoIndex.h" -#include "CellIDAndLAC.h" #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/ReferenceRelation.c b/src/core/libs/supl/asn-rrlp/ReferenceRelation.c index 08cca6413..811339594 100644 --- a/src/core/libs/supl/asn-rrlp/ReferenceRelation.c +++ b/src/core/libs/supl/asn-rrlp/ReferenceRelation.c @@ -7,8 +7,8 @@ #include "ReferenceRelation.h" int ReferenceRelation_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { /* Replace with underlying type checker */ td->check_constraints = asn_DEF_ENUMERATED.check_constraints; @@ -40,77 +40,77 @@ static void ReferenceRelation_1_inherit_TYPE_descriptor( } void ReferenceRelation_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { ReferenceRelation_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int ReferenceRelation_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, + void *app_key) { ReferenceRelation_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t ReferenceRelation_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, + const void *bufptr, size_t size, + int tag_mode) { ReferenceRelation_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t ReferenceRelation_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { ReferenceRelation_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t ReferenceRelation_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { ReferenceRelation_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t ReferenceRelation_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { ReferenceRelation_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t ReferenceRelation_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { ReferenceRelation_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t ReferenceRelation_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { ReferenceRelation_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/ReferenceTime.c b/src/core/libs/supl/asn-rrlp/ReferenceTime.c index f783b26a8..4b9972b2e 100644 --- a/src/core/libs/supl/asn-rrlp/ReferenceTime.c +++ b/src/core/libs/supl/asn-rrlp/ReferenceTime.c @@ -8,21 +8,21 @@ static asn_TYPE_member_t asn_MBR_ReferenceTime_1[] = { {ATF_NOFLAGS, 0, offsetof(struct ReferenceTime, gpsTime), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GPSTime, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "gpsTime"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GPSTime, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "gpsTime"}, {ATF_POINTER, 2, offsetof(struct ReferenceTime, gsmTime), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GSMTime, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "gsmTime"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GSMTime, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "gsmTime"}, {ATF_POINTER, 1, offsetof(struct ReferenceTime, gpsTowAssist), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GPSTOWAssist, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "gpsTowAssist"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GPSTOWAssist, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "gpsTowAssist"}, }; static int asn_MAP_ReferenceTime_oms_1[] = {1, 2}; static ber_tlv_tag_t asn_DEF_ReferenceTime_tags_1[] = { @@ -62,7 +62,7 @@ asn_TYPE_descriptor_t asn_DEF_ReferenceTime = { asn_DEF_ReferenceTime_tags_1, /* Same as above */ sizeof(asn_DEF_ReferenceTime_tags_1) / sizeof(asn_DEF_ReferenceTime_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_ReferenceTime_1, 3, /* Elements count */ &asn_SPC_ReferenceTime_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/ReferenceTime.h b/src/core/libs/supl/asn-rrlp/ReferenceTime.h index bda66b758..84f890f36 100644 --- a/src/core/libs/supl/asn-rrlp/ReferenceTime.h +++ b/src/core/libs/supl/asn-rrlp/ReferenceTime.h @@ -41,8 +41,8 @@ extern "C" #endif /* Referred external types */ -#include "GSMTime.h" #include "GPSTOWAssist.h" +#include "GSMTime.h" #endif /* _ReferenceTime_H_ */ #include diff --git a/src/core/libs/supl/asn-rrlp/ReferenceWGS84.c b/src/core/libs/supl/asn-rrlp/ReferenceWGS84.c index aaea13d45..baa47259b 100644 --- a/src/core/libs/supl/asn-rrlp/ReferenceWGS84.c +++ b/src/core/libs/supl/asn-rrlp/ReferenceWGS84.c @@ -8,23 +8,23 @@ static asn_TYPE_member_t asn_MBR_ReferenceWGS84_1[] = { {ATF_NOFLAGS, 0, offsetof(struct ReferenceWGS84, relativeNorth), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_RelDistance, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "relativeNorth"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_RelDistance, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "relativeNorth"}, {ATF_NOFLAGS, 0, offsetof(struct ReferenceWGS84, relativeEast), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_RelDistance, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "relativeEast"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_RelDistance, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "relativeEast"}, {ATF_POINTER, 1, offsetof(struct ReferenceWGS84, relativeAlt), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_RelativeAlt, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "relativeAlt"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_RelativeAlt, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "relativeAlt"}, }; static int asn_MAP_ReferenceWGS84_oms_1[] = {2}; static ber_tlv_tag_t asn_DEF_ReferenceWGS84_tags_1[] = { @@ -64,7 +64,7 @@ asn_TYPE_descriptor_t asn_DEF_ReferenceWGS84 = { asn_DEF_ReferenceWGS84_tags_1, /* Same as above */ sizeof(asn_DEF_ReferenceWGS84_tags_1) / sizeof(asn_DEF_ReferenceWGS84_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_ReferenceWGS84_1, 3, /* Elements count */ &asn_SPC_ReferenceWGS84_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/Rel-5-MsrPosition-Rsp-Extension.c b/src/core/libs/supl/asn-rrlp/Rel-5-MsrPosition-Rsp-Extension.c index 89dcd0796..99d0a70bb 100644 --- a/src/core/libs/supl/asn-rrlp/Rel-5-MsrPosition-Rsp-Extension.c +++ b/src/core/libs/supl/asn-rrlp/Rel-5-MsrPosition-Rsp-Extension.c @@ -8,26 +8,26 @@ static asn_TYPE_member_t asn_MBR_Rel_5_MsrPosition_Rsp_Extension_1[] = { {ATF_POINTER, 3, - offsetof(struct Rel_5_MsrPosition_Rsp_Extension, extended_reference), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Extended_reference, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "extended-reference"}, + offsetof(struct Rel_5_MsrPosition_Rsp_Extension, extended_reference), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Extended_reference, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "extended-reference"}, {ATF_POINTER, 2, - offsetof(struct Rel_5_MsrPosition_Rsp_Extension, otd_MeasureInfo_5_Ext), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_OTD_MeasureInfo_5_Ext, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "otd-MeasureInfo-5-Ext"}, + offsetof(struct Rel_5_MsrPosition_Rsp_Extension, otd_MeasureInfo_5_Ext), + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_OTD_MeasureInfo_5_Ext, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "otd-MeasureInfo-5-Ext"}, {ATF_POINTER, 1, - offsetof(struct Rel_5_MsrPosition_Rsp_Extension, ulPseudoSegInd), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_UlPseudoSegInd, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ulPseudoSegInd"}, + offsetof(struct Rel_5_MsrPosition_Rsp_Extension, ulPseudoSegInd), + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_UlPseudoSegInd, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ulPseudoSegInd"}, }; static int asn_MAP_Rel_5_MsrPosition_Rsp_Extension_oms_1[] = {0, 1, 2}; static ber_tlv_tag_t asn_DEF_Rel_5_MsrPosition_Rsp_Extension_tags_1[] = { @@ -35,18 +35,18 @@ static ber_tlv_tag_t asn_DEF_Rel_5_MsrPosition_Rsp_Extension_tags_1[] = { static asn_TYPE_tag2member_t asn_MAP_Rel_5_MsrPosition_Rsp_Extension_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0}, /* extended-reference at 985 */ + 0}, /* extended-reference at 985 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0}, /* otd-MeasureInfo-5-Ext at 991 */ + 0}, /* otd-MeasureInfo-5-Ext at 991 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, - 0} /* ulPseudoSegInd at 992 */ + 0} /* ulPseudoSegInd at 992 */ }; static asn_SEQUENCE_specifics_t asn_SPC_Rel_5_MsrPosition_Rsp_Extension_specs_1 = { sizeof(struct Rel_5_MsrPosition_Rsp_Extension), offsetof(struct Rel_5_MsrPosition_Rsp_Extension, _asn_ctx), asn_MAP_Rel_5_MsrPosition_Rsp_Extension_tag2el_1, - 3, /* Count of tags in the map */ + 3, /* Count of tags in the map */ asn_MAP_Rel_5_MsrPosition_Rsp_Extension_oms_1, /* Optional members */ 3, 0, /* Root/Additions */ @@ -69,10 +69,10 @@ asn_TYPE_descriptor_t asn_DEF_Rel_5_MsrPosition_Rsp_Extension = { asn_DEF_Rel_5_MsrPosition_Rsp_Extension_tags_1, sizeof(asn_DEF_Rel_5_MsrPosition_Rsp_Extension_tags_1) / sizeof(asn_DEF_Rel_5_MsrPosition_Rsp_Extension_tags_1[0]), /* 1 */ - asn_DEF_Rel_5_MsrPosition_Rsp_Extension_tags_1, /* Same as above */ + asn_DEF_Rel_5_MsrPosition_Rsp_Extension_tags_1, /* Same as above */ sizeof(asn_DEF_Rel_5_MsrPosition_Rsp_Extension_tags_1) / sizeof(asn_DEF_Rel_5_MsrPosition_Rsp_Extension_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_Rel_5_MsrPosition_Rsp_Extension_1, 3, /* Elements count */ &asn_SPC_Rel_5_MsrPosition_Rsp_Extension_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/Rel-5-ProtocolError-Extension.c b/src/core/libs/supl/asn-rrlp/Rel-5-ProtocolError-Extension.c index e76a67c0c..fd6dfc33d 100644 --- a/src/core/libs/supl/asn-rrlp/Rel-5-ProtocolError-Extension.c +++ b/src/core/libs/supl/asn-rrlp/Rel-5-ProtocolError-Extension.c @@ -8,12 +8,12 @@ static asn_TYPE_member_t asn_MBR_Rel_5_ProtocolError_Extension_1[] = { {ATF_POINTER, 1, - offsetof(struct Rel_5_ProtocolError_Extension, extended_reference), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Extended_reference, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "extended-reference"}, + offsetof(struct Rel_5_ProtocolError_Extension, extended_reference), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Extended_reference, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "extended-reference"}, }; static int asn_MAP_Rel_5_ProtocolError_Extension_oms_1[] = {0}; static ber_tlv_tag_t asn_DEF_Rel_5_ProtocolError_Extension_tags_1[] = { @@ -21,14 +21,14 @@ static ber_tlv_tag_t asn_DEF_Rel_5_ProtocolError_Extension_tags_1[] = { static asn_TYPE_tag2member_t asn_MAP_Rel_5_ProtocolError_Extension_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0} /* extended-reference at 1030 */ + 0} /* extended-reference at 1030 */ }; static asn_SEQUENCE_specifics_t asn_SPC_Rel_5_ProtocolError_Extension_specs_1 = { sizeof(struct Rel_5_ProtocolError_Extension), offsetof(struct Rel_5_ProtocolError_Extension, _asn_ctx), asn_MAP_Rel_5_ProtocolError_Extension_tag2el_1, - 1, /* Count of tags in the map */ + 1, /* Count of tags in the map */ asn_MAP_Rel_5_ProtocolError_Extension_oms_1, /* Optional members */ 1, 0, /* Root/Additions */ @@ -51,10 +51,10 @@ asn_TYPE_descriptor_t asn_DEF_Rel_5_ProtocolError_Extension = { asn_DEF_Rel_5_ProtocolError_Extension_tags_1, sizeof(asn_DEF_Rel_5_ProtocolError_Extension_tags_1) / sizeof(asn_DEF_Rel_5_ProtocolError_Extension_tags_1[0]), /* 1 */ - asn_DEF_Rel_5_ProtocolError_Extension_tags_1, /* Same as above */ + asn_DEF_Rel_5_ProtocolError_Extension_tags_1, /* Same as above */ sizeof(asn_DEF_Rel_5_ProtocolError_Extension_tags_1) / sizeof(asn_DEF_Rel_5_ProtocolError_Extension_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_Rel_5_ProtocolError_Extension_1, 1, /* Elements count */ &asn_SPC_Rel_5_ProtocolError_Extension_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/Rel-7-MsrPosition-Rsp-Extension.c b/src/core/libs/supl/asn-rrlp/Rel-7-MsrPosition-Rsp-Extension.c index c4f31654c..417a1abff 100644 --- a/src/core/libs/supl/asn-rrlp/Rel-7-MsrPosition-Rsp-Extension.c +++ b/src/core/libs/supl/asn-rrlp/Rel-7-MsrPosition-Rsp-Extension.c @@ -8,26 +8,26 @@ static asn_TYPE_member_t asn_MBR_Rel_7_MsrPosition_Rsp_Extension_1[] = { {ATF_POINTER, 3, - offsetof(struct Rel_7_MsrPosition_Rsp_Extension, velEstimate), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_VelocityEstimate, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "velEstimate"}, + offsetof(struct Rel_7_MsrPosition_Rsp_Extension, velEstimate), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_VelocityEstimate, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "velEstimate"}, {ATF_POINTER, 2, - offsetof(struct Rel_7_MsrPosition_Rsp_Extension, ganssLocationInfo), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSLocationInfo, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssLocationInfo"}, + offsetof(struct Rel_7_MsrPosition_Rsp_Extension, ganssLocationInfo), + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSLocationInfo, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssLocationInfo"}, {ATF_POINTER, 1, - offsetof(struct Rel_7_MsrPosition_Rsp_Extension, ganssMeasureInfo), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSMeasureInfo, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssMeasureInfo"}, + offsetof(struct Rel_7_MsrPosition_Rsp_Extension, ganssMeasureInfo), + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSMeasureInfo, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssMeasureInfo"}, }; static int asn_MAP_Rel_7_MsrPosition_Rsp_Extension_oms_1[] = {0, 1, 2}; static ber_tlv_tag_t asn_DEF_Rel_7_MsrPosition_Rsp_Extension_tags_1[] = { @@ -36,16 +36,16 @@ static asn_TYPE_tag2member_t asn_MAP_Rel_7_MsrPosition_Rsp_Extension_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* velEstimate at 1397 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0}, /* ganssLocationInfo at 1402 */ + 0}, /* ganssLocationInfo at 1402 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, - 0} /* ganssMeasureInfo at 1403 */ + 0} /* ganssMeasureInfo at 1403 */ }; static asn_SEQUENCE_specifics_t asn_SPC_Rel_7_MsrPosition_Rsp_Extension_specs_1 = { sizeof(struct Rel_7_MsrPosition_Rsp_Extension), offsetof(struct Rel_7_MsrPosition_Rsp_Extension, _asn_ctx), asn_MAP_Rel_7_MsrPosition_Rsp_Extension_tag2el_1, - 3, /* Count of tags in the map */ + 3, /* Count of tags in the map */ asn_MAP_Rel_7_MsrPosition_Rsp_Extension_oms_1, /* Optional members */ 3, 0, /* Root/Additions */ @@ -68,10 +68,10 @@ asn_TYPE_descriptor_t asn_DEF_Rel_7_MsrPosition_Rsp_Extension = { asn_DEF_Rel_7_MsrPosition_Rsp_Extension_tags_1, sizeof(asn_DEF_Rel_7_MsrPosition_Rsp_Extension_tags_1) / sizeof(asn_DEF_Rel_7_MsrPosition_Rsp_Extension_tags_1[0]), /* 1 */ - asn_DEF_Rel_7_MsrPosition_Rsp_Extension_tags_1, /* Same as above */ + asn_DEF_Rel_7_MsrPosition_Rsp_Extension_tags_1, /* Same as above */ sizeof(asn_DEF_Rel_7_MsrPosition_Rsp_Extension_tags_1) / sizeof(asn_DEF_Rel_7_MsrPosition_Rsp_Extension_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_Rel_7_MsrPosition_Rsp_Extension_1, 3, /* Elements count */ &asn_SPC_Rel_7_MsrPosition_Rsp_Extension_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/Rel-98-MsrPosition-Rsp-Extension.c b/src/core/libs/supl/asn-rrlp/Rel-98-MsrPosition-Rsp-Extension.c index fac4e015c..bf6f21fbe 100644 --- a/src/core/libs/supl/asn-rrlp/Rel-98-MsrPosition-Rsp-Extension.c +++ b/src/core/libs/supl/asn-rrlp/Rel-98-MsrPosition-Rsp-Extension.c @@ -8,19 +8,19 @@ static asn_TYPE_member_t asn_MBR_rel_98_Ext_MeasureInfo_2[] = { {ATF_POINTER, 1, - offsetof(struct rel_98_Ext_MeasureInfo, otd_MeasureInfo_R98_Ext), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_OTD_MeasureInfo_R98_Ext, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "otd-MeasureInfo-R98-Ext"}, + offsetof(struct rel_98_Ext_MeasureInfo, otd_MeasureInfo_R98_Ext), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_OTD_MeasureInfo_R98_Ext, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "otd-MeasureInfo-R98-Ext"}, }; static int asn_MAP_rel_98_Ext_MeasureInfo_oms_2[] = {0}; static ber_tlv_tag_t asn_DEF_rel_98_Ext_MeasureInfo_tags_2[] = { (ASN_TAG_CLASS_CONTEXT | (0 << 2)), (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_rel_98_Ext_MeasureInfo_tag2el_2[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0} /* otd-MeasureInfo-R98-Ext at 960 */ + 0} /* otd-MeasureInfo-R98-Ext at 960 */ }; static asn_SEQUENCE_specifics_t asn_SPC_rel_98_Ext_MeasureInfo_specs_2 = { sizeof(struct rel_98_Ext_MeasureInfo), @@ -54,7 +54,7 @@ static /* Use -fall-defs-global to expose */ asn_DEF_rel_98_Ext_MeasureInfo_tags_2, /* Same as above */ sizeof(asn_DEF_rel_98_Ext_MeasureInfo_tags_2) / sizeof(asn_DEF_rel_98_Ext_MeasureInfo_tags_2[0]), /* 2 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_rel_98_Ext_MeasureInfo_2, 1, /* Elements count */ &asn_SPC_rel_98_Ext_MeasureInfo_specs_2 /* Additional specs */ @@ -62,19 +62,19 @@ static /* Use -fall-defs-global to expose */ static asn_TYPE_member_t asn_MBR_Rel_98_MsrPosition_Rsp_Extension_1[] = { {ATF_NOFLAGS, 0, - offsetof(struct Rel_98_MsrPosition_Rsp_Extension, rel_98_Ext_MeasureInfo), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, &asn_DEF_rel_98_Ext_MeasureInfo_2, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "rel-98-Ext-MeasureInfo"}, + offsetof(struct Rel_98_MsrPosition_Rsp_Extension, rel_98_Ext_MeasureInfo), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, &asn_DEF_rel_98_Ext_MeasureInfo_2, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "rel-98-Ext-MeasureInfo"}, {ATF_POINTER, 1, - offsetof(struct Rel_98_MsrPosition_Rsp_Extension, - timeAssistanceMeasurements), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GPSTimeAssistanceMeasurements, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "timeAssistanceMeasurements"}, + offsetof(struct Rel_98_MsrPosition_Rsp_Extension, + timeAssistanceMeasurements), + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GPSTimeAssistanceMeasurements, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "timeAssistanceMeasurements"}, }; static int asn_MAP_Rel_98_MsrPosition_Rsp_Extension_oms_1[] = {1}; static ber_tlv_tag_t asn_DEF_Rel_98_MsrPosition_Rsp_Extension_tags_1[] = { @@ -82,16 +82,16 @@ static ber_tlv_tag_t asn_DEF_Rel_98_MsrPosition_Rsp_Extension_tags_1[] = { static asn_TYPE_tag2member_t asn_MAP_Rel_98_MsrPosition_Rsp_Extension_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0}, /* rel-98-Ext-MeasureInfo at 960 */ + 0}, /* rel-98-Ext-MeasureInfo at 960 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0} /* timeAssistanceMeasurements at 963 */ + 0} /* timeAssistanceMeasurements at 963 */ }; static asn_SEQUENCE_specifics_t asn_SPC_Rel_98_MsrPosition_Rsp_Extension_specs_1 = { sizeof(struct Rel_98_MsrPosition_Rsp_Extension), offsetof(struct Rel_98_MsrPosition_Rsp_Extension, _asn_ctx), asn_MAP_Rel_98_MsrPosition_Rsp_Extension_tag2el_1, - 2, /* Count of tags in the map */ + 2, /* Count of tags in the map */ asn_MAP_Rel_98_MsrPosition_Rsp_Extension_oms_1, /* Optional members */ 0, 1, /* Root/Additions */ @@ -114,10 +114,10 @@ asn_TYPE_descriptor_t asn_DEF_Rel_98_MsrPosition_Rsp_Extension = { asn_DEF_Rel_98_MsrPosition_Rsp_Extension_tags_1, sizeof(asn_DEF_Rel_98_MsrPosition_Rsp_Extension_tags_1) / sizeof(asn_DEF_Rel_98_MsrPosition_Rsp_Extension_tags_1[0]), /* 1 */ - asn_DEF_Rel_98_MsrPosition_Rsp_Extension_tags_1, /* Same as above */ + asn_DEF_Rel_98_MsrPosition_Rsp_Extension_tags_1, /* Same as above */ sizeof(asn_DEF_Rel_98_MsrPosition_Rsp_Extension_tags_1) / sizeof(asn_DEF_Rel_98_MsrPosition_Rsp_Extension_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_Rel_98_MsrPosition_Rsp_Extension_1, 2, /* Elements count */ &asn_SPC_Rel_98_MsrPosition_Rsp_Extension_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/Rel5-AssistanceData-Extension.c b/src/core/libs/supl/asn-rrlp/Rel5-AssistanceData-Extension.c index 31398433d..2b2d268ef 100644 --- a/src/core/libs/supl/asn-rrlp/Rel5-AssistanceData-Extension.c +++ b/src/core/libs/supl/asn-rrlp/Rel5-AssistanceData-Extension.c @@ -8,19 +8,19 @@ static asn_TYPE_member_t asn_MBR_Rel5_AssistanceData_Extension_1[] = { {ATF_NOFLAGS, 0, - offsetof(struct Rel5_AssistanceData_Extension, extended_reference), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Extended_reference, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "extended-reference"}, + offsetof(struct Rel5_AssistanceData_Extension, extended_reference), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Extended_reference, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "extended-reference"}, }; static ber_tlv_tag_t asn_DEF_Rel5_AssistanceData_Extension_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_Rel5_AssistanceData_Extension_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0} /* extended-reference at 1023 */ + 0} /* extended-reference at 1023 */ }; static asn_SEQUENCE_specifics_t asn_SPC_Rel5_AssistanceData_Extension_specs_1 = { @@ -50,10 +50,10 @@ asn_TYPE_descriptor_t asn_DEF_Rel5_AssistanceData_Extension = { asn_DEF_Rel5_AssistanceData_Extension_tags_1, sizeof(asn_DEF_Rel5_AssistanceData_Extension_tags_1) / sizeof(asn_DEF_Rel5_AssistanceData_Extension_tags_1[0]), /* 1 */ - asn_DEF_Rel5_AssistanceData_Extension_tags_1, /* Same as above */ + asn_DEF_Rel5_AssistanceData_Extension_tags_1, /* Same as above */ sizeof(asn_DEF_Rel5_AssistanceData_Extension_tags_1) / sizeof(asn_DEF_Rel5_AssistanceData_Extension_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_Rel5_AssistanceData_Extension_1, 1, /* Elements count */ &asn_SPC_Rel5_AssistanceData_Extension_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/Rel5-MsrPosition-Req-Extension.c b/src/core/libs/supl/asn-rrlp/Rel5-MsrPosition-Req-Extension.c index 0f67e8000..628968945 100644 --- a/src/core/libs/supl/asn-rrlp/Rel5-MsrPosition-Req-Extension.c +++ b/src/core/libs/supl/asn-rrlp/Rel5-MsrPosition-Req-Extension.c @@ -8,19 +8,19 @@ static asn_TYPE_member_t asn_MBR_Rel5_MsrPosition_Req_Extension_1[] = { {ATF_NOFLAGS, 0, - offsetof(struct Rel5_MsrPosition_Req_Extension, extended_reference), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Extended_reference, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "extended-reference"}, + offsetof(struct Rel5_MsrPosition_Req_Extension, extended_reference), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Extended_reference, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "extended-reference"}, }; static ber_tlv_tag_t asn_DEF_Rel5_MsrPosition_Req_Extension_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_Rel5_MsrPosition_Req_Extension_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0} /* extended-reference at 1017 */ + 0} /* extended-reference at 1017 */ }; static asn_SEQUENCE_specifics_t asn_SPC_Rel5_MsrPosition_Req_Extension_specs_1 = { @@ -50,10 +50,10 @@ asn_TYPE_descriptor_t asn_DEF_Rel5_MsrPosition_Req_Extension = { asn_DEF_Rel5_MsrPosition_Req_Extension_tags_1, sizeof(asn_DEF_Rel5_MsrPosition_Req_Extension_tags_1) / sizeof(asn_DEF_Rel5_MsrPosition_Req_Extension_tags_1[0]), /* 1 */ - asn_DEF_Rel5_MsrPosition_Req_Extension_tags_1, /* Same as above */ + asn_DEF_Rel5_MsrPosition_Req_Extension_tags_1, /* Same as above */ sizeof(asn_DEF_Rel5_MsrPosition_Req_Extension_tags_1) / sizeof(asn_DEF_Rel5_MsrPosition_Req_Extension_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_Rel5_MsrPosition_Req_Extension_1, 1, /* Elements count */ &asn_SPC_Rel5_MsrPosition_Req_Extension_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/Rel7-AssistanceData-Extension.c b/src/core/libs/supl/asn-rrlp/Rel7-AssistanceData-Extension.c index 9a1ad5c2c..b4bf88e3b 100644 --- a/src/core/libs/supl/asn-rrlp/Rel7-AssistanceData-Extension.c +++ b/src/core/libs/supl/asn-rrlp/Rel7-AssistanceData-Extension.c @@ -8,26 +8,26 @@ static asn_TYPE_member_t asn_MBR_Rel7_AssistanceData_Extension_1[] = { {ATF_POINTER, 3, - offsetof(struct Rel7_AssistanceData_Extension, ganss_AssistData), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSS_AssistData, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganss-AssistData"}, + offsetof(struct Rel7_AssistanceData_Extension, ganss_AssistData), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSS_AssistData, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganss-AssistData"}, {ATF_POINTER, 2, - offsetof(struct Rel7_AssistanceData_Extension, - ganssCarrierPhaseMeasurementRequest), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NULL, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssCarrierPhaseMeasurementRequest"}, + offsetof(struct Rel7_AssistanceData_Extension, + ganssCarrierPhaseMeasurementRequest), + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NULL, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssCarrierPhaseMeasurementRequest"}, {ATF_POINTER, 1, - offsetof(struct Rel7_AssistanceData_Extension, - ganssTODGSMTimeAssociationMeasurementRequest), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NULL, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssTODGSMTimeAssociationMeasurementRequest"}, + offsetof(struct Rel7_AssistanceData_Extension, + ganssTODGSMTimeAssociationMeasurementRequest), + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NULL, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssTODGSMTimeAssociationMeasurementRequest"}, }; static int asn_MAP_Rel7_AssistanceData_Extension_oms_1[] = {0, 1, 2}; static ber_tlv_tag_t asn_DEF_Rel7_AssistanceData_Extension_tags_1[] = { @@ -35,18 +35,18 @@ static ber_tlv_tag_t asn_DEF_Rel7_AssistanceData_Extension_tags_1[] = { static asn_TYPE_tag2member_t asn_MAP_Rel7_AssistanceData_Extension_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0}, /* ganss-AssistData at 1491 */ + 0}, /* ganss-AssistData at 1491 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0}, /* ganssCarrierPhaseMeasurementRequest at 1492 */ + 0}, /* ganssCarrierPhaseMeasurementRequest at 1492 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, - 0} /* ganssTODGSMTimeAssociationMeasurementRequest at 1493 */ + 0} /* ganssTODGSMTimeAssociationMeasurementRequest at 1493 */ }; static asn_SEQUENCE_specifics_t asn_SPC_Rel7_AssistanceData_Extension_specs_1 = { sizeof(struct Rel7_AssistanceData_Extension), offsetof(struct Rel7_AssistanceData_Extension, _asn_ctx), asn_MAP_Rel7_AssistanceData_Extension_tag2el_1, - 3, /* Count of tags in the map */ + 3, /* Count of tags in the map */ asn_MAP_Rel7_AssistanceData_Extension_oms_1, /* Optional members */ 3, 0, /* Root/Additions */ @@ -69,10 +69,10 @@ asn_TYPE_descriptor_t asn_DEF_Rel7_AssistanceData_Extension = { asn_DEF_Rel7_AssistanceData_Extension_tags_1, sizeof(asn_DEF_Rel7_AssistanceData_Extension_tags_1) / sizeof(asn_DEF_Rel7_AssistanceData_Extension_tags_1[0]), /* 1 */ - asn_DEF_Rel7_AssistanceData_Extension_tags_1, /* Same as above */ + asn_DEF_Rel7_AssistanceData_Extension_tags_1, /* Same as above */ sizeof(asn_DEF_Rel7_AssistanceData_Extension_tags_1) / sizeof(asn_DEF_Rel7_AssistanceData_Extension_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_Rel7_AssistanceData_Extension_1, 3, /* Elements count */ &asn_SPC_Rel7_AssistanceData_Extension_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/Rel7-MsrPosition-Req-Extension.c b/src/core/libs/supl/asn-rrlp/Rel7-MsrPosition-Req-Extension.c index c78a04553..b816cf651 100644 --- a/src/core/libs/supl/asn-rrlp/Rel7-MsrPosition-Req-Extension.c +++ b/src/core/libs/supl/asn-rrlp/Rel7-MsrPosition-Req-Extension.c @@ -8,46 +8,46 @@ static asn_TYPE_member_t asn_MBR_Rel7_MsrPosition_Req_Extension_1[] = { {ATF_POINTER, 6, - offsetof(struct Rel7_MsrPosition_Req_Extension, velocityRequested), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NULL, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "velocityRequested"}, + offsetof(struct Rel7_MsrPosition_Req_Extension, velocityRequested), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NULL, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "velocityRequested"}, {ATF_POINTER, 5, - offsetof(struct Rel7_MsrPosition_Req_Extension, ganssPositionMethod), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSPositioningMethod, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssPositionMethod"}, + offsetof(struct Rel7_MsrPosition_Req_Extension, ganssPositionMethod), + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSPositioningMethod, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssPositionMethod"}, {ATF_POINTER, 4, - offsetof(struct Rel7_MsrPosition_Req_Extension, ganss_AssistData), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSS_AssistData, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganss-AssistData"}, + offsetof(struct Rel7_MsrPosition_Req_Extension, ganss_AssistData), + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSS_AssistData, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganss-AssistData"}, {ATF_POINTER, 3, - offsetof(struct Rel7_MsrPosition_Req_Extension, - ganssCarrierPhaseMeasurementRequest), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NULL, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssCarrierPhaseMeasurementRequest"}, + offsetof(struct Rel7_MsrPosition_Req_Extension, + ganssCarrierPhaseMeasurementRequest), + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NULL, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssCarrierPhaseMeasurementRequest"}, {ATF_POINTER, 2, - offsetof(struct Rel7_MsrPosition_Req_Extension, - ganssTODGSMTimeAssociationMeasurementRequest), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NULL, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssTODGSMTimeAssociationMeasurementRequest"}, + offsetof(struct Rel7_MsrPosition_Req_Extension, + ganssTODGSMTimeAssociationMeasurementRequest), + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NULL, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssTODGSMTimeAssociationMeasurementRequest"}, {ATF_POINTER, 1, - offsetof(struct Rel7_MsrPosition_Req_Extension, requiredResponseTime), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_RequiredResponseTime, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "requiredResponseTime"}, + offsetof(struct Rel7_MsrPosition_Req_Extension, requiredResponseTime), + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_RequiredResponseTime, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "requiredResponseTime"}, }; static int asn_MAP_Rel7_MsrPosition_Req_Extension_oms_1[] = {0, 1, 2, 3, 4, 5}; static ber_tlv_tag_t asn_DEF_Rel7_MsrPosition_Req_Extension_tags_1[] = { @@ -55,24 +55,24 @@ static ber_tlv_tag_t asn_DEF_Rel7_MsrPosition_Req_Extension_tags_1[] = { static asn_TYPE_tag2member_t asn_MAP_Rel7_MsrPosition_Req_Extension_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0}, /* velocityRequested at 1045 */ + 0}, /* velocityRequested at 1045 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0}, /* ganssPositionMethod at 1046 */ + 0}, /* ganssPositionMethod at 1046 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, - 0}, /* ganss-AssistData at 1047 */ + 0}, /* ganss-AssistData at 1047 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, - 0}, /* ganssCarrierPhaseMeasurementRequest at 1048 */ + 0}, /* ganssCarrierPhaseMeasurementRequest at 1048 */ {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, - 0}, /* ganssTODGSMTimeAssociationMeasurementRequest at 1049 */ + 0}, /* ganssTODGSMTimeAssociationMeasurementRequest at 1049 */ {(ASN_TAG_CLASS_CONTEXT | (5 << 2)), 5, 0, - 0} /* requiredResponseTime at 1050 */ + 0} /* requiredResponseTime at 1050 */ }; static asn_SEQUENCE_specifics_t asn_SPC_Rel7_MsrPosition_Req_Extension_specs_1 = { sizeof(struct Rel7_MsrPosition_Req_Extension), offsetof(struct Rel7_MsrPosition_Req_Extension, _asn_ctx), asn_MAP_Rel7_MsrPosition_Req_Extension_tag2el_1, - 6, /* Count of tags in the map */ + 6, /* Count of tags in the map */ asn_MAP_Rel7_MsrPosition_Req_Extension_oms_1, /* Optional members */ 6, 0, /* Root/Additions */ @@ -95,10 +95,10 @@ asn_TYPE_descriptor_t asn_DEF_Rel7_MsrPosition_Req_Extension = { asn_DEF_Rel7_MsrPosition_Req_Extension_tags_1, sizeof(asn_DEF_Rel7_MsrPosition_Req_Extension_tags_1) / sizeof(asn_DEF_Rel7_MsrPosition_Req_Extension_tags_1[0]), /* 1 */ - asn_DEF_Rel7_MsrPosition_Req_Extension_tags_1, /* Same as above */ + asn_DEF_Rel7_MsrPosition_Req_Extension_tags_1, /* Same as above */ sizeof(asn_DEF_Rel7_MsrPosition_Req_Extension_tags_1) / sizeof(asn_DEF_Rel7_MsrPosition_Req_Extension_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_Rel7_MsrPosition_Req_Extension_1, 6, /* Elements count */ &asn_SPC_Rel7_MsrPosition_Req_Extension_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/Rel7-MsrPosition-Req-Extension.h b/src/core/libs/supl/asn-rrlp/Rel7-MsrPosition-Req-Extension.h index 424e919a8..252399c1f 100644 --- a/src/core/libs/supl/asn-rrlp/Rel7-MsrPosition-Req-Extension.h +++ b/src/core/libs/supl/asn-rrlp/Rel7-MsrPosition-Req-Extension.h @@ -10,9 +10,9 @@ #include /* Including external dependencies */ -#include #include "GANSSPositioningMethod.h" #include "RequiredResponseTime.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/Rel98-AssistanceData-Extension.c b/src/core/libs/supl/asn-rrlp/Rel98-AssistanceData-Extension.c index a83981a21..f93d5434e 100644 --- a/src/core/libs/supl/asn-rrlp/Rel98-AssistanceData-Extension.c +++ b/src/core/libs/supl/asn-rrlp/Rel98-AssistanceData-Extension.c @@ -8,27 +8,27 @@ static asn_TYPE_member_t asn_MBR_Rel98_AssistanceData_Extension_1[] = { {ATF_POINTER, 3, - offsetof(struct Rel98_AssistanceData_Extension, rel98_Ext_ExpOTD), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Rel98_Ext_ExpOTD, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "rel98-Ext-ExpOTD"}, + offsetof(struct Rel98_AssistanceData_Extension, rel98_Ext_ExpOTD), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Rel98_Ext_ExpOTD, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "rel98-Ext-ExpOTD"}, {ATF_POINTER, 2, - offsetof(struct Rel98_AssistanceData_Extension, - gpsTimeAssistanceMeasurementRequest), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NULL, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "gpsTimeAssistanceMeasurementRequest"}, + offsetof(struct Rel98_AssistanceData_Extension, + gpsTimeAssistanceMeasurementRequest), + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NULL, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "gpsTimeAssistanceMeasurementRequest"}, {ATF_POINTER, 1, - offsetof(struct Rel98_AssistanceData_Extension, - gpsReferenceTimeUncertainty), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GPSReferenceTimeUncertainty, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "gpsReferenceTimeUncertainty"}, + offsetof(struct Rel98_AssistanceData_Extension, + gpsReferenceTimeUncertainty), + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GPSReferenceTimeUncertainty, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "gpsReferenceTimeUncertainty"}, }; static int asn_MAP_Rel98_AssistanceData_Extension_oms_1[] = {0, 1, 2}; static ber_tlv_tag_t asn_DEF_Rel98_AssistanceData_Extension_tags_1[] = { @@ -36,18 +36,18 @@ static ber_tlv_tag_t asn_DEF_Rel98_AssistanceData_Extension_tags_1[] = { static asn_TYPE_tag2member_t asn_MAP_Rel98_AssistanceData_Extension_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0}, /* rel98-Ext-ExpOTD at 879 */ + 0}, /* rel98-Ext-ExpOTD at 879 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0}, /* gpsTimeAssistanceMeasurementRequest at 881 */ + 0}, /* gpsTimeAssistanceMeasurementRequest at 881 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, - 0} /* gpsReferenceTimeUncertainty at 882 */ + 0} /* gpsReferenceTimeUncertainty at 882 */ }; static asn_SEQUENCE_specifics_t asn_SPC_Rel98_AssistanceData_Extension_specs_1 = { sizeof(struct Rel98_AssistanceData_Extension), offsetof(struct Rel98_AssistanceData_Extension, _asn_ctx), asn_MAP_Rel98_AssistanceData_Extension_tag2el_1, - 3, /* Count of tags in the map */ + 3, /* Count of tags in the map */ asn_MAP_Rel98_AssistanceData_Extension_oms_1, /* Optional members */ 1, 2, /* Root/Additions */ @@ -70,10 +70,10 @@ asn_TYPE_descriptor_t asn_DEF_Rel98_AssistanceData_Extension = { asn_DEF_Rel98_AssistanceData_Extension_tags_1, sizeof(asn_DEF_Rel98_AssistanceData_Extension_tags_1) / sizeof(asn_DEF_Rel98_AssistanceData_Extension_tags_1[0]), /* 1 */ - asn_DEF_Rel98_AssistanceData_Extension_tags_1, /* Same as above */ + asn_DEF_Rel98_AssistanceData_Extension_tags_1, /* Same as above */ sizeof(asn_DEF_Rel98_AssistanceData_Extension_tags_1) / sizeof(asn_DEF_Rel98_AssistanceData_Extension_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_Rel98_AssistanceData_Extension_1, 3, /* Elements count */ &asn_SPC_Rel98_AssistanceData_Extension_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/Rel98-AssistanceData-Extension.h b/src/core/libs/supl/asn-rrlp/Rel98-AssistanceData-Extension.h index 9238ccbf3..e484437a6 100644 --- a/src/core/libs/supl/asn-rrlp/Rel98-AssistanceData-Extension.h +++ b/src/core/libs/supl/asn-rrlp/Rel98-AssistanceData-Extension.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include #include "GPSReferenceTimeUncertainty.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/Rel98-Ext-ExpOTD.c b/src/core/libs/supl/asn-rrlp/Rel98-Ext-ExpOTD.c index 500ee581f..625a54928 100644 --- a/src/core/libs/supl/asn-rrlp/Rel98-Ext-ExpOTD.c +++ b/src/core/libs/supl/asn-rrlp/Rel98-Ext-ExpOTD.c @@ -8,28 +8,28 @@ static asn_TYPE_member_t asn_MBR_Rel98_Ext_ExpOTD_1[] = { {ATF_POINTER, 2, - offsetof(struct Rel98_Ext_ExpOTD, msrAssistData_R98_ExpOTD), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_MsrAssistData_R98_ExpOTD, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "msrAssistData-R98-ExpOTD"}, + offsetof(struct Rel98_Ext_ExpOTD, msrAssistData_R98_ExpOTD), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_MsrAssistData_R98_ExpOTD, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "msrAssistData-R98-ExpOTD"}, {ATF_POINTER, 1, - offsetof(struct Rel98_Ext_ExpOTD, systemInfoAssistData_R98_ExpOTD), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SystemInfoAssistData_R98_ExpOTD, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "systemInfoAssistData-R98-ExpOTD"}, + offsetof(struct Rel98_Ext_ExpOTD, systemInfoAssistData_R98_ExpOTD), + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SystemInfoAssistData_R98_ExpOTD, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "systemInfoAssistData-R98-ExpOTD"}, }; static int asn_MAP_Rel98_Ext_ExpOTD_oms_1[] = {0, 1}; static ber_tlv_tag_t asn_DEF_Rel98_Ext_ExpOTD_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_Rel98_Ext_ExpOTD_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0}, /* msrAssistData-R98-ExpOTD at 890 */ + 0}, /* msrAssistData-R98-ExpOTD at 890 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0} /* systemInfoAssistData-R98-ExpOTD at 894 */ + 0} /* systemInfoAssistData-R98-ExpOTD at 894 */ }; static asn_SEQUENCE_specifics_t asn_SPC_Rel98_Ext_ExpOTD_specs_1 = { sizeof(struct Rel98_Ext_ExpOTD), @@ -61,7 +61,7 @@ asn_TYPE_descriptor_t asn_DEF_Rel98_Ext_ExpOTD = { asn_DEF_Rel98_Ext_ExpOTD_tags_1, /* Same as above */ sizeof(asn_DEF_Rel98_Ext_ExpOTD_tags_1) / sizeof(asn_DEF_Rel98_Ext_ExpOTD_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_Rel98_Ext_ExpOTD_1, 2, /* Elements count */ &asn_SPC_Rel98_Ext_ExpOTD_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/Rel98-MsrPosition-Req-Extension.c b/src/core/libs/supl/asn-rrlp/Rel98-MsrPosition-Req-Extension.c index 5b28f808f..6c4b1b324 100644 --- a/src/core/libs/supl/asn-rrlp/Rel98-MsrPosition-Req-Extension.c +++ b/src/core/libs/supl/asn-rrlp/Rel98-MsrPosition-Req-Extension.c @@ -8,27 +8,27 @@ static asn_TYPE_member_t asn_MBR_Rel98_MsrPosition_Req_Extension_1[] = { {ATF_POINTER, 3, - offsetof(struct Rel98_MsrPosition_Req_Extension, rel98_Ext_ExpOTD), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Rel98_Ext_ExpOTD, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "rel98-Ext-ExpOTD"}, + offsetof(struct Rel98_MsrPosition_Req_Extension, rel98_Ext_ExpOTD), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Rel98_Ext_ExpOTD, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "rel98-Ext-ExpOTD"}, {ATF_POINTER, 2, - offsetof(struct Rel98_MsrPosition_Req_Extension, - gpsTimeAssistanceMeasurementRequest), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NULL, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "gpsTimeAssistanceMeasurementRequest"}, + offsetof(struct Rel98_MsrPosition_Req_Extension, + gpsTimeAssistanceMeasurementRequest), + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NULL, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "gpsTimeAssistanceMeasurementRequest"}, {ATF_POINTER, 1, - offsetof(struct Rel98_MsrPosition_Req_Extension, - gpsReferenceTimeUncertainty), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GPSReferenceTimeUncertainty, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "gpsReferenceTimeUncertainty"}, + offsetof(struct Rel98_MsrPosition_Req_Extension, + gpsReferenceTimeUncertainty), + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GPSReferenceTimeUncertainty, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "gpsReferenceTimeUncertainty"}, }; static int asn_MAP_Rel98_MsrPosition_Req_Extension_oms_1[] = {0, 1, 2}; static ber_tlv_tag_t asn_DEF_Rel98_MsrPosition_Req_Extension_tags_1[] = { @@ -36,18 +36,18 @@ static ber_tlv_tag_t asn_DEF_Rel98_MsrPosition_Req_Extension_tags_1[] = { static asn_TYPE_tag2member_t asn_MAP_Rel98_MsrPosition_Req_Extension_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0}, /* rel98-Ext-ExpOTD at 871 */ + 0}, /* rel98-Ext-ExpOTD at 871 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0}, /* gpsTimeAssistanceMeasurementRequest at 873 */ + 0}, /* gpsTimeAssistanceMeasurementRequest at 873 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, - 0} /* gpsReferenceTimeUncertainty at 874 */ + 0} /* gpsReferenceTimeUncertainty at 874 */ }; static asn_SEQUENCE_specifics_t asn_SPC_Rel98_MsrPosition_Req_Extension_specs_1 = { sizeof(struct Rel98_MsrPosition_Req_Extension), offsetof(struct Rel98_MsrPosition_Req_Extension, _asn_ctx), asn_MAP_Rel98_MsrPosition_Req_Extension_tag2el_1, - 3, /* Count of tags in the map */ + 3, /* Count of tags in the map */ asn_MAP_Rel98_MsrPosition_Req_Extension_oms_1, /* Optional members */ 1, 2, /* Root/Additions */ @@ -70,10 +70,10 @@ asn_TYPE_descriptor_t asn_DEF_Rel98_MsrPosition_Req_Extension = { asn_DEF_Rel98_MsrPosition_Req_Extension_tags_1, sizeof(asn_DEF_Rel98_MsrPosition_Req_Extension_tags_1) / sizeof(asn_DEF_Rel98_MsrPosition_Req_Extension_tags_1[0]), /* 1 */ - asn_DEF_Rel98_MsrPosition_Req_Extension_tags_1, /* Same as above */ + asn_DEF_Rel98_MsrPosition_Req_Extension_tags_1, /* Same as above */ sizeof(asn_DEF_Rel98_MsrPosition_Req_Extension_tags_1) / sizeof(asn_DEF_Rel98_MsrPosition_Req_Extension_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_Rel98_MsrPosition_Req_Extension_1, 3, /* Elements count */ &asn_SPC_Rel98_MsrPosition_Req_Extension_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/Rel98-MsrPosition-Req-Extension.h b/src/core/libs/supl/asn-rrlp/Rel98-MsrPosition-Req-Extension.h index 1d785c7ba..7597c58af 100644 --- a/src/core/libs/supl/asn-rrlp/Rel98-MsrPosition-Req-Extension.h +++ b/src/core/libs/supl/asn-rrlp/Rel98-MsrPosition-Req-Extension.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include #include "GPSReferenceTimeUncertainty.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/RelDistance.c b/src/core/libs/supl/asn-rrlp/RelDistance.c index e2624f0df..95a2ee2c2 100644 --- a/src/core/libs/supl/asn-rrlp/RelDistance.c +++ b/src/core/libs/supl/asn-rrlp/RelDistance.c @@ -7,14 +7,14 @@ #include "RelDistance.h" int RelDistance_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int RelDistance_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -55,73 +55,73 @@ static void RelDistance_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void RelDistance_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { RelDistance_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int RelDistance_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { RelDistance_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t RelDistance_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { RelDistance_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t RelDistance_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { RelDistance_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t RelDistance_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, const char *opt_mname, + const void *bufptr, size_t size) { RelDistance_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t RelDistance_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { RelDistance_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t RelDistance_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { RelDistance_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t RelDistance_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { RelDistance_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/RelativeAlt.c b/src/core/libs/supl/asn-rrlp/RelativeAlt.c index f92227b37..2ee3b41b5 100644 --- a/src/core/libs/supl/asn-rrlp/RelativeAlt.c +++ b/src/core/libs/supl/asn-rrlp/RelativeAlt.c @@ -7,14 +7,14 @@ #include "RelativeAlt.h" int RelativeAlt_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int RelativeAlt_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -55,73 +55,73 @@ static void RelativeAlt_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void RelativeAlt_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { RelativeAlt_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int RelativeAlt_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { RelativeAlt_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t RelativeAlt_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { RelativeAlt_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t RelativeAlt_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { RelativeAlt_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t RelativeAlt_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, const char *opt_mname, + const void *bufptr, size_t size) { RelativeAlt_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t RelativeAlt_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { RelativeAlt_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t RelativeAlt_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { RelativeAlt_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t RelativeAlt_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { RelativeAlt_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/RequestIndex.c b/src/core/libs/supl/asn-rrlp/RequestIndex.c index 7c9441dde..d7258d484 100644 --- a/src/core/libs/supl/asn-rrlp/RequestIndex.c +++ b/src/core/libs/supl/asn-rrlp/RequestIndex.c @@ -7,15 +7,15 @@ #include "RequestIndex.h" int RequestIndex_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ int RequestIndex_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -56,74 +56,74 @@ static void RequestIndex_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void RequestIndex_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { RequestIndex_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int RequestIndex_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { RequestIndex_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t RequestIndex_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { RequestIndex_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t RequestIndex_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { RequestIndex_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t RequestIndex_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, const char *opt_mname, + const void *bufptr, size_t size) { RequestIndex_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t RequestIndex_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { RequestIndex_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t RequestIndex_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { RequestIndex_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t RequestIndex_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { RequestIndex_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/RequiredResponseTime.c b/src/core/libs/supl/asn-rrlp/RequiredResponseTime.c index f167d8354..69f42a357 100644 --- a/src/core/libs/supl/asn-rrlp/RequiredResponseTime.c +++ b/src/core/libs/supl/asn-rrlp/RequiredResponseTime.c @@ -7,15 +7,15 @@ #include "RequiredResponseTime.h" int RequiredResponseTime_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ int RequiredResponseTime_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -57,57 +57,57 @@ static void RequiredResponseTime_1_inherit_TYPE_descriptor( } void RequiredResponseTime_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { RequiredResponseTime_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int RequiredResponseTime_print(asn_TYPE_descriptor_t *td, - const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + const void *struct_ptr, int ilevel, + asn_app_consume_bytes_f *cb, void *app_key) { RequiredResponseTime_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t RequiredResponseTime_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, + const void *bufptr, size_t size, + int tag_mode) { RequiredResponseTime_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t RequiredResponseTime_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { RequiredResponseTime_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t RequiredResponseTime_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { RequiredResponseTime_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t RequiredResponseTime_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { RequiredResponseTime_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); @@ -120,7 +120,7 @@ asn_dec_rval_t RequiredResponseTime_decode_uper( { RequiredResponseTime_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t RequiredResponseTime_encode_uper( diff --git a/src/core/libs/supl/asn-rrlp/RoughRTD.c b/src/core/libs/supl/asn-rrlp/RoughRTD.c index 8e773c3f5..f732d8122 100644 --- a/src/core/libs/supl/asn-rrlp/RoughRTD.c +++ b/src/core/libs/supl/asn-rrlp/RoughRTD.c @@ -7,14 +7,14 @@ #include "RoughRTD.h" int RoughRTD_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int RoughRTD_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -55,68 +55,68 @@ static void RoughRTD_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void RoughRTD_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { RoughRTD_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int RoughRTD_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { RoughRTD_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t RoughRTD_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, + int tag_mode) { RoughRTD_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t RoughRTD_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { RoughRTD_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t RoughRTD_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { RoughRTD_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t RoughRTD_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { RoughRTD_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t RoughRTD_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { RoughRTD_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t RoughRTD_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { RoughRTD_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/SVID.c b/src/core/libs/supl/asn-rrlp/SVID.c index 207f5fd99..7641aa054 100644 --- a/src/core/libs/supl/asn-rrlp/SVID.c +++ b/src/core/libs/supl/asn-rrlp/SVID.c @@ -7,14 +7,14 @@ #include "SVID.h" int SVID_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int SVID_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -61,60 +61,60 @@ void SVID_free(asn_TYPE_descriptor_t *td, void *struct_ptr, int contents_only) } int SVID_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { SVID_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t SVID_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, int tag_mode) { SVID_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t SVID_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { SVID_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t SVID_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { SVID_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t SVID_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { SVID_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t SVID_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { SVID_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t SVID_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { SVID_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); @@ -143,7 +143,7 @@ asn_TYPE_descriptor_t asn_DEF_SVID = { 0, /* Use generic outmost tag fetcher */ asn_DEF_SVID_tags_1, sizeof(asn_DEF_SVID_tags_1) / sizeof(asn_DEF_SVID_tags_1[0]), /* 1 */ - asn_DEF_SVID_tags_1, /* Same as above */ + asn_DEF_SVID_tags_1, /* Same as above */ sizeof(asn_DEF_SVID_tags_1) / sizeof(asn_DEF_SVID_tags_1[0]), /* 1 */ &ASN_PER_TYPE_SVID_CONSTR_1, 0, diff --git a/src/core/libs/supl/asn-rrlp/SVIDMASK.c b/src/core/libs/supl/asn-rrlp/SVIDMASK.c index cd553ccfc..8ea8e2e77 100644 --- a/src/core/libs/supl/asn-rrlp/SVIDMASK.c +++ b/src/core/libs/supl/asn-rrlp/SVIDMASK.c @@ -7,7 +7,7 @@ #include "SVIDMASK.h" int SVIDMASK_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { const BIT_STRING_t *st = (const BIT_STRING_t *)sptr; size_t size; @@ -15,7 +15,7 @@ int SVIDMASK_constraint(asn_TYPE_descriptor_t *td, const void *sptr, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -37,7 +37,7 @@ int SVIDMASK_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -64,68 +64,68 @@ static void SVIDMASK_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void SVIDMASK_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { SVIDMASK_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int SVIDMASK_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { SVIDMASK_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t SVIDMASK_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, + int tag_mode) { SVIDMASK_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t SVIDMASK_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { SVIDMASK_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t SVIDMASK_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { SVIDMASK_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t SVIDMASK_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { SVIDMASK_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t SVIDMASK_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { SVIDMASK_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t SVIDMASK_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { SVIDMASK_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/SatElement.c b/src/core/libs/supl/asn-rrlp/SatElement.c index cf9a25061..d3f124815 100644 --- a/src/core/libs/supl/asn-rrlp/SatElement.c +++ b/src/core/libs/supl/asn-rrlp/SatElement.c @@ -7,15 +7,15 @@ #include "SatElement.h" static int memb_iode_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,21 +29,21 @@ static int memb_iode_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_udre_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -57,7 +57,7 @@ static int memb_udre_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -71,7 +71,7 @@ static int memb_pseudoRangeCor_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -85,22 +85,22 @@ static int memb_pseudoRangeCor_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_rangeRateCor_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -114,7 +114,7 @@ static int memb_rangeRateCor_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -128,7 +128,7 @@ static int memb_deltaPseudoRangeCor2_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -142,7 +142,7 @@ static int memb_deltaPseudoRangeCor2_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -156,7 +156,7 @@ static int memb_deltaRangeRateCor2_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -170,7 +170,7 @@ static int memb_deltaRangeRateCor2_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -184,7 +184,7 @@ static int memb_deltaPseudoRangeCor3_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -198,7 +198,7 @@ static int memb_deltaPseudoRangeCor3_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -212,7 +212,7 @@ static int memb_deltaRangeRateCor3_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -226,7 +226,7 @@ static int memb_deltaRangeRateCor3_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -281,43 +281,43 @@ static asn_per_constraints_t ASN_PER_MEMB_DELTA_RANGE_RATE_COR3_CONSTR_10 = { }; static asn_TYPE_member_t asn_MBR_SatElement_1[] = { {ATF_NOFLAGS, 0, offsetof(struct SatElement, satelliteID), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SatelliteID, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "satelliteID"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SatelliteID, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "satelliteID"}, {ATF_NOFLAGS, 0, offsetof(struct SatElement, iode), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_iode_constraint_1, - &ASN_PER_MEMB_IODE_CONSTR_3, 0, "iode"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_iode_constraint_1, + &ASN_PER_MEMB_IODE_CONSTR_3, 0, "iode"}, {ATF_NOFLAGS, 0, offsetof(struct SatElement, udre), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_udre_constraint_1, - &ASN_PER_MEMB_UDRE_CONSTR_4, 0, "udre"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_udre_constraint_1, + &ASN_PER_MEMB_UDRE_CONSTR_4, 0, "udre"}, {ATF_NOFLAGS, 0, offsetof(struct SatElement, pseudoRangeCor), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_pseudoRangeCor_constraint_1, - &ASN_PER_MEMB_PSEUDO_RANGE_COR_CONSTR_5, 0, "pseudoRangeCor"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_pseudoRangeCor_constraint_1, + &ASN_PER_MEMB_PSEUDO_RANGE_COR_CONSTR_5, 0, "pseudoRangeCor"}, {ATF_NOFLAGS, 0, offsetof(struct SatElement, rangeRateCor), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_rangeRateCor_constraint_1, - &ASN_PER_MEMB_RANGE_RATE_COR_CONSTR_6, 0, "rangeRateCor"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_rangeRateCor_constraint_1, + &ASN_PER_MEMB_RANGE_RATE_COR_CONSTR_6, 0, "rangeRateCor"}, {ATF_NOFLAGS, 0, offsetof(struct SatElement, deltaPseudoRangeCor2), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_deltaPseudoRangeCor2_constraint_1, - &ASN_PER_MEMB_DELTA_PSEUDO_RANGE_COR2_CONSTR_7, 0, "deltaPseudoRangeCor2"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_deltaPseudoRangeCor2_constraint_1, + &ASN_PER_MEMB_DELTA_PSEUDO_RANGE_COR2_CONSTR_7, 0, "deltaPseudoRangeCor2"}, {ATF_NOFLAGS, 0, offsetof(struct SatElement, deltaRangeRateCor2), - (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_deltaRangeRateCor2_constraint_1, - &ASN_PER_MEMB_DELTA_RANGE_RATE_COR2_CONSTR_8, 0, "deltaRangeRateCor2"}, + (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_deltaRangeRateCor2_constraint_1, + &ASN_PER_MEMB_DELTA_RANGE_RATE_COR2_CONSTR_8, 0, "deltaRangeRateCor2"}, {ATF_NOFLAGS, 0, offsetof(struct SatElement, deltaPseudoRangeCor3), - (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_deltaPseudoRangeCor3_constraint_1, - &ASN_PER_MEMB_DELTA_PSEUDO_RANGE_COR3_CONSTR_9, 0, "deltaPseudoRangeCor3"}, + (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_deltaPseudoRangeCor3_constraint_1, + &ASN_PER_MEMB_DELTA_PSEUDO_RANGE_COR3_CONSTR_9, 0, "deltaPseudoRangeCor3"}, {ATF_NOFLAGS, 0, offsetof(struct SatElement, deltaRangeRateCor3), - (ASN_TAG_CLASS_CONTEXT | (8 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_deltaRangeRateCor3_constraint_1, - &ASN_PER_MEMB_DELTA_RANGE_RATE_COR3_CONSTR_10, 0, "deltaRangeRateCor3"}, + (ASN_TAG_CLASS_CONTEXT | (8 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_deltaRangeRateCor3_constraint_1, + &ASN_PER_MEMB_DELTA_RANGE_RATE_COR3_CONSTR_10, 0, "deltaRangeRateCor3"}, }; static ber_tlv_tag_t asn_DEF_SatElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -328,13 +328,13 @@ static asn_TYPE_tag2member_t asn_MAP_SatElement_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, 0}, /* pseudoRangeCor at 673 */ {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, 0}, /* rangeRateCor at 677 */ {(ASN_TAG_CLASS_CONTEXT | (5 << 2)), 5, 0, - 0}, /* deltaPseudoRangeCor2 at 680 */ + 0}, /* deltaPseudoRangeCor2 at 680 */ {(ASN_TAG_CLASS_CONTEXT | (6 << 2)), 6, 0, - 0}, /* deltaRangeRateCor2 at 683 */ + 0}, /* deltaRangeRateCor2 at 683 */ {(ASN_TAG_CLASS_CONTEXT | (7 << 2)), 7, 0, - 0}, /* deltaPseudoRangeCor3 at 686 */ + 0}, /* deltaPseudoRangeCor3 at 686 */ {(ASN_TAG_CLASS_CONTEXT | (8 << 2)), 8, 0, - 0} /* deltaRangeRateCor3 at 689 */ + 0} /* deltaRangeRateCor3 at 689 */ }; static asn_SEQUENCE_specifics_t asn_SPC_SatElement_specs_1 = { sizeof(struct SatElement), diff --git a/src/core/libs/supl/asn-rrlp/SatStatus.c b/src/core/libs/supl/asn-rrlp/SatStatus.c index 7fc1d03a8..28d05fb98 100644 --- a/src/core/libs/supl/asn-rrlp/SatStatus.c +++ b/src/core/libs/supl/asn-rrlp/SatStatus.c @@ -14,28 +14,28 @@ static asn_per_constraints_t ASN_PER_TYPE_SAT_STATUS_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_SatStatus_1[] = { {ATF_NOFLAGS, 0, offsetof(struct SatStatus, choice.newSatelliteAndModelUC), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_UncompressedEphemeris, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "newSatelliteAndModelUC"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_UncompressedEphemeris, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "newSatelliteAndModelUC"}, {ATF_NOFLAGS, 0, offsetof(struct SatStatus, choice.oldSatelliteAndModel), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NULL, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "oldSatelliteAndModel"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NULL, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "oldSatelliteAndModel"}, {ATF_NOFLAGS, 0, offsetof(struct SatStatus, choice.newNaviModelUC), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_UncompressedEphemeris, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "newNaviModelUC"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_UncompressedEphemeris, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "newNaviModelUC"}, }; static asn_TYPE_tag2member_t asn_MAP_SatStatus_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0}, /* newSatelliteAndModelUC at 710 */ + 0}, /* newSatelliteAndModelUC at 710 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0}, /* oldSatelliteAndModel at 713 */ + 0}, /* oldSatelliteAndModel at 713 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0} /* newNaviModelUC at 716 */ }; static asn_CHOICE_specifics_t asn_SPC_SatStatus_specs_1 = { diff --git a/src/core/libs/supl/asn-rrlp/SatelliteID.c b/src/core/libs/supl/asn-rrlp/SatelliteID.c index 30d66d529..f9724baed 100644 --- a/src/core/libs/supl/asn-rrlp/SatelliteID.c +++ b/src/core/libs/supl/asn-rrlp/SatelliteID.c @@ -7,14 +7,14 @@ #include "SatelliteID.h" int SatelliteID_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int SatelliteID_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -55,73 +55,73 @@ static void SatelliteID_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void SatelliteID_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { SatelliteID_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int SatelliteID_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { SatelliteID_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t SatelliteID_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { SatelliteID_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t SatelliteID_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { SatelliteID_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t SatelliteID_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, const char *opt_mname, + const void *bufptr, size_t size) { SatelliteID_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t SatelliteID_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { SatelliteID_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t SatelliteID_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { SatelliteID_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t SatelliteID_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { SatelliteID_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/SeqOf-BadSatelliteSet.c b/src/core/libs/supl/asn-rrlp/SeqOf-BadSatelliteSet.c index ab1c4ee2f..ffee0762a 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOf-BadSatelliteSet.c +++ b/src/core/libs/supl/asn-rrlp/SeqOf-BadSatelliteSet.c @@ -14,10 +14,10 @@ static asn_per_constraints_t ASN_PER_TYPE_SEQ_OF_BAD_SATELLITE_SET_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_SeqOf_BadSatelliteSet_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)), 0, - &asn_DEF_SatelliteID, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_SatelliteID, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOf_BadSatelliteSet_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/SeqOf-GANSSDataBits.c b/src/core/libs/supl/asn-rrlp/SeqOf-GANSSDataBits.c index 172e65172..652dde30c 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOf-GANSSDataBits.c +++ b/src/core/libs/supl/asn-rrlp/SeqOf-GANSSDataBits.c @@ -14,10 +14,10 @@ static asn_per_constraints_t ASN_PER_TYPE_SEQ_OF_GANSS_DATA_BITS_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_SeqOf_GANSSDataBits_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)), 0, - &asn_DEF_GANSSDataBit, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_GANSSDataBit, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOf_GANSSDataBits_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/SeqOfAcquisElement.c b/src/core/libs/supl/asn-rrlp/SeqOfAcquisElement.c index 1aeff9d77..f929218e1 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfAcquisElement.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfAcquisElement.c @@ -14,10 +14,10 @@ static asn_per_constraints_t ASN_PER_TYPE_SEQ_OF_ACQUIS_ELEMENT_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_SeqOfAcquisElement_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_AcquisElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_AcquisElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfAcquisElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/SeqOfAlmanacElement.c b/src/core/libs/supl/asn-rrlp/SeqOfAlmanacElement.c index 35f590953..972f2c7d6 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfAlmanacElement.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfAlmanacElement.c @@ -14,10 +14,10 @@ static asn_per_constraints_t ASN_PER_TYPE_SEQ_OF_ALMANAC_ELEMENT_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_SeqOfAlmanacElement_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_AlmanacElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_AlmanacElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfAlmanacElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/SeqOfBadSignalElement.c b/src/core/libs/supl/asn-rrlp/SeqOfBadSignalElement.c index 225da2729..d08095854 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfBadSignalElement.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfBadSignalElement.c @@ -14,10 +14,10 @@ static asn_per_constraints_t ASN_PER_TYPE_SEQ_OF_BAD_SIGNAL_ELEMENT_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_SeqOfBadSignalElement_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_BadSignalElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_BadSignalElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfBadSignalElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/SeqOfDGANSSSgnElement.c b/src/core/libs/supl/asn-rrlp/SeqOfDGANSSSgnElement.c index b07e09a50..a67b0b8d4 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfDGANSSSgnElement.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfDGANSSSgnElement.c @@ -14,10 +14,10 @@ static asn_per_constraints_t ASN_PER_TYPE_SEQ_OF_DGANSS_SGN_ELEMENT_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_SeqOfDGANSSSgnElement_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_DGANSSSgnElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_DGANSSSgnElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfDGANSSSgnElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/SeqOfGANSS-MsrSetElement.c b/src/core/libs/supl/asn-rrlp/SeqOfGANSS-MsrSetElement.c index 454ced504..faf816eaf 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfGANSS-MsrSetElement.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfGANSS-MsrSetElement.c @@ -15,10 +15,10 @@ static asn_per_constraints_t }; static asn_TYPE_member_t asn_MBR_SeqOfGANSS_MsrSetElement_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_GANSS_MsrSetElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_GANSS_MsrSetElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfGANSS_MsrSetElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/SeqOfGANSS-SgnElement.c b/src/core/libs/supl/asn-rrlp/SeqOfGANSS-SgnElement.c index efe0b08fa..1a2d85782 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfGANSS-SgnElement.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfGANSS-SgnElement.c @@ -14,10 +14,10 @@ static asn_per_constraints_t ASN_PER_TYPE_SEQ_OF_GANSS_SGN_ELEMENT_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_SeqOfGANSS_SgnElement_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_GANSS_SgnElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_GANSS_SgnElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfGANSS_SgnElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/SeqOfGANSS-SgnTypeElement.c b/src/core/libs/supl/asn-rrlp/SeqOfGANSS-SgnTypeElement.c index e2013b8d4..8ae387292 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfGANSS-SgnTypeElement.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfGANSS-SgnTypeElement.c @@ -15,10 +15,10 @@ static asn_per_constraints_t }; static asn_TYPE_member_t asn_MBR_SeqOfGANSS_SgnTypeElement_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_GANSS_SgnTypeElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_GANSS_SgnTypeElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfGANSS_SgnTypeElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/SeqOfGANSSAlmanacElement.c b/src/core/libs/supl/asn-rrlp/SeqOfGANSSAlmanacElement.c index fdaae1587..25c4702c8 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfGANSSAlmanacElement.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfGANSSAlmanacElement.c @@ -15,10 +15,10 @@ static asn_per_constraints_t }; static asn_TYPE_member_t asn_MBR_SeqOfGANSSAlmanacElement_1[] = { {ATF_POINTER, 0, 0, -1 /* Ambiguous tag (CHOICE?) */, 0, - &asn_DEF_GANSSAlmanacElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_GANSSAlmanacElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfGANSSAlmanacElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/SeqOfGANSSGenericAssistDataElement.c b/src/core/libs/supl/asn-rrlp/SeqOfGANSSGenericAssistDataElement.c index 3e6aae21e..aa2517fc0 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfGANSSGenericAssistDataElement.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfGANSSGenericAssistDataElement.c @@ -15,10 +15,10 @@ static asn_per_constraints_t }; static asn_TYPE_member_t asn_MBR_SeqOfGANSSGenericAssistDataElement_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_GANSSGenericAssistDataElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_GANSSGenericAssistDataElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfGANSSGenericAssistDataElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -44,7 +44,7 @@ asn_TYPE_descriptor_t asn_DEF_SeqOfGANSSGenericAssistDataElement = { asn_DEF_SeqOfGANSSGenericAssistDataElement_tags_1, sizeof(asn_DEF_SeqOfGANSSGenericAssistDataElement_tags_1) / sizeof(asn_DEF_SeqOfGANSSGenericAssistDataElement_tags_1[0]), /* 1 */ - asn_DEF_SeqOfGANSSGenericAssistDataElement_tags_1, /* Same as above */ + asn_DEF_SeqOfGANSSGenericAssistDataElement_tags_1, /* Same as above */ sizeof(asn_DEF_SeqOfGANSSGenericAssistDataElement_tags_1) / sizeof(asn_DEF_SeqOfGANSSGenericAssistDataElement_tags_1[0]), /* 1 */ &ASN_PER_TYPE_SEQ_OF_GANSS_GENERIC_ASSIST_DATA_ELEMENT_CONSTR_1, diff --git a/src/core/libs/supl/asn-rrlp/SeqOfGANSSRefMeasurementElement.c b/src/core/libs/supl/asn-rrlp/SeqOfGANSSRefMeasurementElement.c index 53d8469a3..631634048 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfGANSSRefMeasurementElement.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfGANSSRefMeasurementElement.c @@ -15,10 +15,10 @@ static asn_per_constraints_t }; static asn_TYPE_member_t asn_MBR_SeqOfGANSSRefMeasurementElement_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_GANSSRefMeasurementElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_GANSSRefMeasurementElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfGANSSRefMeasurementElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -44,7 +44,7 @@ asn_TYPE_descriptor_t asn_DEF_SeqOfGANSSRefMeasurementElement = { asn_DEF_SeqOfGANSSRefMeasurementElement_tags_1, sizeof(asn_DEF_SeqOfGANSSRefMeasurementElement_tags_1) / sizeof(asn_DEF_SeqOfGANSSRefMeasurementElement_tags_1[0]), /* 1 */ - asn_DEF_SeqOfGANSSRefMeasurementElement_tags_1, /* Same as above */ + asn_DEF_SeqOfGANSSRefMeasurementElement_tags_1, /* Same as above */ sizeof(asn_DEF_SeqOfGANSSRefMeasurementElement_tags_1) / sizeof(asn_DEF_SeqOfGANSSRefMeasurementElement_tags_1[0]), /* 1 */ &ASN_PER_TYPE_SEQ_OF_GANSS_REF_MEASUREMENT_ELEMENT_CONSTR_1, diff --git a/src/core/libs/supl/asn-rrlp/SeqOfGANSSSatelliteElement.c b/src/core/libs/supl/asn-rrlp/SeqOfGANSSSatelliteElement.c index 9788e28c3..4d04d925e 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfGANSSSatelliteElement.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfGANSSSatelliteElement.c @@ -15,10 +15,10 @@ static asn_per_constraints_t }; static asn_TYPE_member_t asn_MBR_SeqOfGANSSSatelliteElement_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_GANSSSatelliteElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_GANSSSatelliteElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfGANSSSatelliteElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -43,7 +43,7 @@ asn_TYPE_descriptor_t asn_DEF_SeqOfGANSSSatelliteElement = { asn_DEF_SeqOfGANSSSatelliteElement_tags_1, sizeof(asn_DEF_SeqOfGANSSSatelliteElement_tags_1) / sizeof(asn_DEF_SeqOfGANSSSatelliteElement_tags_1[0]), /* 1 */ - asn_DEF_SeqOfGANSSSatelliteElement_tags_1, /* Same as above */ + asn_DEF_SeqOfGANSSSatelliteElement_tags_1, /* Same as above */ sizeof(asn_DEF_SeqOfGANSSSatelliteElement_tags_1) / sizeof(asn_DEF_SeqOfGANSSSatelliteElement_tags_1[0]), /* 1 */ &ASN_PER_TYPE_SEQ_OF_GANSS_SATELLITE_ELEMENT_CONSTR_1, diff --git a/src/core/libs/supl/asn-rrlp/SeqOfGANSSTimeModel.c b/src/core/libs/supl/asn-rrlp/SeqOfGANSSTimeModel.c index 6861e5b3f..ff306ef12 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfGANSSTimeModel.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfGANSSTimeModel.c @@ -14,10 +14,10 @@ static asn_per_constraints_t ASN_PER_TYPE_SEQ_OF_GANSS_TIME_MODEL_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_SeqOfGANSSTimeModel_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_GANSSTimeModelElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_GANSSTimeModelElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfGANSSTimeModel_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/SeqOfGPS-MsrElement.c b/src/core/libs/supl/asn-rrlp/SeqOfGPS-MsrElement.c index 99d3ebb67..c17dc3185 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfGPS-MsrElement.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfGPS-MsrElement.c @@ -14,10 +14,10 @@ static asn_per_constraints_t ASN_PER_TYPE_SEQ_OF_GPS_MSR_ELEMENT_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_SeqOfGPS_MsrElement_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_GPS_MsrElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_GPS_MsrElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfGPS_MsrElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/SeqOfGPS-MsrSetElement.c b/src/core/libs/supl/asn-rrlp/SeqOfGPS-MsrSetElement.c index a990f4f38..cb24dba04 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfGPS-MsrSetElement.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfGPS-MsrSetElement.c @@ -15,10 +15,10 @@ static asn_per_constraints_t ASN_PER_TYPE_SEQ_OF_GPS_MSR_SET_ELEMENT_CONSTR_1 = }; static asn_TYPE_member_t asn_MBR_SeqOfGPS_MsrSetElement_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_GPS_MsrSetElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_GPS_MsrSetElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfGPS_MsrSetElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/SeqOfMsrAssistBTS-R98-ExpOTD.c b/src/core/libs/supl/asn-rrlp/SeqOfMsrAssistBTS-R98-ExpOTD.c index 3ee788715..715480fb7 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfMsrAssistBTS-R98-ExpOTD.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfMsrAssistBTS-R98-ExpOTD.c @@ -15,10 +15,10 @@ static asn_per_constraints_t }; static asn_TYPE_member_t asn_MBR_SeqOfMsrAssistBTS_R98_ExpOTD_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_MsrAssistBTS_R98_ExpOTD, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_MsrAssistBTS_R98_ExpOTD, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfMsrAssistBTS_R98_ExpOTD_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -43,7 +43,7 @@ asn_TYPE_descriptor_t asn_DEF_SeqOfMsrAssistBTS_R98_ExpOTD = { asn_DEF_SeqOfMsrAssistBTS_R98_ExpOTD_tags_1, sizeof(asn_DEF_SeqOfMsrAssistBTS_R98_ExpOTD_tags_1) / sizeof(asn_DEF_SeqOfMsrAssistBTS_R98_ExpOTD_tags_1[0]), /* 1 */ - asn_DEF_SeqOfMsrAssistBTS_R98_ExpOTD_tags_1, /* Same as above */ + asn_DEF_SeqOfMsrAssistBTS_R98_ExpOTD_tags_1, /* Same as above */ sizeof(asn_DEF_SeqOfMsrAssistBTS_R98_ExpOTD_tags_1) / sizeof(asn_DEF_SeqOfMsrAssistBTS_R98_ExpOTD_tags_1[0]), /* 1 */ &ASN_PER_TYPE_SEQ_OF_MSR_ASSIST_BTS_R98_EXP_OTD_CONSTR_1, diff --git a/src/core/libs/supl/asn-rrlp/SeqOfMsrAssistBTS.c b/src/core/libs/supl/asn-rrlp/SeqOfMsrAssistBTS.c index 54238ae86..a3d7d81d7 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfMsrAssistBTS.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfMsrAssistBTS.c @@ -14,10 +14,10 @@ static asn_per_constraints_t ASN_PER_TYPE_SEQ_OF_MSR_ASSIST_BTS_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_SeqOfMsrAssistBTS_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_MsrAssistBTS, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_MsrAssistBTS, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfMsrAssistBTS_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/SeqOfNavModelElement.c b/src/core/libs/supl/asn-rrlp/SeqOfNavModelElement.c index ecf87d4c8..732f2a5e8 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfNavModelElement.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfNavModelElement.c @@ -14,10 +14,10 @@ static asn_per_constraints_t ASN_PER_TYPE_SEQ_OF_NAV_MODEL_ELEMENT_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_SeqOfNavModelElement_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_NavModelElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_NavModelElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfNavModelElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/SeqOfOTD-FirstSetMsrs-R98-Ext.c b/src/core/libs/supl/asn-rrlp/SeqOfOTD-FirstSetMsrs-R98-Ext.c index c84e758a1..bb75fe216 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfOTD-FirstSetMsrs-R98-Ext.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfOTD-FirstSetMsrs-R98-Ext.c @@ -15,10 +15,10 @@ static asn_per_constraints_t }; static asn_TYPE_member_t asn_MBR_SeqOfOTD_FirstSetMsrs_R98_Ext_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_OTD_FirstSetMsrs, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_OTD_FirstSetMsrs, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfOTD_FirstSetMsrs_R98_Ext_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -43,7 +43,7 @@ asn_TYPE_descriptor_t asn_DEF_SeqOfOTD_FirstSetMsrs_R98_Ext = { asn_DEF_SeqOfOTD_FirstSetMsrs_R98_Ext_tags_1, sizeof(asn_DEF_SeqOfOTD_FirstSetMsrs_R98_Ext_tags_1) / sizeof(asn_DEF_SeqOfOTD_FirstSetMsrs_R98_Ext_tags_1[0]), /* 1 */ - asn_DEF_SeqOfOTD_FirstSetMsrs_R98_Ext_tags_1, /* Same as above */ + asn_DEF_SeqOfOTD_FirstSetMsrs_R98_Ext_tags_1, /* Same as above */ sizeof(asn_DEF_SeqOfOTD_FirstSetMsrs_R98_Ext_tags_1) / sizeof(asn_DEF_SeqOfOTD_FirstSetMsrs_R98_Ext_tags_1[0]), /* 1 */ &ASN_PER_TYPE_SEQ_OF_OTD_FIRST_SET_MSRS_R98_EXT_CONSTR_1, diff --git a/src/core/libs/supl/asn-rrlp/SeqOfOTD-FirstSetMsrs.c b/src/core/libs/supl/asn-rrlp/SeqOfOTD-FirstSetMsrs.c index 3fd18b74f..758f5b91e 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfOTD-FirstSetMsrs.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfOTD-FirstSetMsrs.c @@ -14,10 +14,10 @@ static asn_per_constraints_t ASN_PER_TYPE_SEQ_OF_OTD_FIRST_SET_MSRS_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_SeqOfOTD_FirstSetMsrs_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_OTD_FirstSetMsrs, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_OTD_FirstSetMsrs, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfOTD_FirstSetMsrs_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/SeqOfOTD-MsrElementRest.c b/src/core/libs/supl/asn-rrlp/SeqOfOTD-MsrElementRest.c index d93a8834e..9df3cb3fc 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfOTD-MsrElementRest.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfOTD-MsrElementRest.c @@ -15,10 +15,10 @@ static asn_per_constraints_t ASN_PER_TYPE_SEQ_OF_OTD_MSR_ELEMENT_REST_CONSTR_1 = }; static asn_TYPE_member_t asn_MBR_SeqOfOTD_MsrElementRest_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_OTD_MsrElementRest, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_OTD_MsrElementRest, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfOTD_MsrElementRest_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/SeqOfOTD-MsrsOfOtherSets.c b/src/core/libs/supl/asn-rrlp/SeqOfOTD-MsrsOfOtherSets.c index 030e737eb..e8510f586 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfOTD-MsrsOfOtherSets.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfOTD-MsrsOfOtherSets.c @@ -15,10 +15,10 @@ static asn_per_constraints_t }; static asn_TYPE_member_t asn_MBR_SeqOfOTD_MsrsOfOtherSets_1[] = { {ATF_POINTER, 0, 0, -1 /* Ambiguous tag (CHOICE?) */, 0, - &asn_DEF_OTD_MsrsOfOtherSets, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_OTD_MsrsOfOtherSets, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfOTD_MsrsOfOtherSets_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/SeqOfReferenceIdentityType.c b/src/core/libs/supl/asn-rrlp/SeqOfReferenceIdentityType.c index e8c91385f..55c39b8c1 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfReferenceIdentityType.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfReferenceIdentityType.c @@ -15,10 +15,10 @@ static asn_per_constraints_t }; static asn_TYPE_member_t asn_MBR_SeqOfReferenceIdentityType_1[] = { {ATF_POINTER, 0, 0, -1 /* Ambiguous tag (CHOICE?) */, 0, - &asn_DEF_ReferenceIdentityType, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_ReferenceIdentityType, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfReferenceIdentityType_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -43,7 +43,7 @@ asn_TYPE_descriptor_t asn_DEF_SeqOfReferenceIdentityType = { asn_DEF_SeqOfReferenceIdentityType_tags_1, sizeof(asn_DEF_SeqOfReferenceIdentityType_tags_1) / sizeof(asn_DEF_SeqOfReferenceIdentityType_tags_1[0]), /* 1 */ - asn_DEF_SeqOfReferenceIdentityType_tags_1, /* Same as above */ + asn_DEF_SeqOfReferenceIdentityType_tags_1, /* Same as above */ sizeof(asn_DEF_SeqOfReferenceIdentityType_tags_1) / sizeof(asn_DEF_SeqOfReferenceIdentityType_tags_1[0]), /* 1 */ &ASN_PER_TYPE_SEQ_OF_REFERENCE_IDENTITY_TYPE_CONSTR_1, diff --git a/src/core/libs/supl/asn-rrlp/SeqOfSatElement.c b/src/core/libs/supl/asn-rrlp/SeqOfSatElement.c index e824a864d..85dddc59d 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfSatElement.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfSatElement.c @@ -14,9 +14,9 @@ static asn_per_constraints_t ASN_PER_TYPE_SEQ_OF_SAT_ELEMENT_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_SeqOfSatElement_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_SatElement, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_SatElement, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfSatElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/SeqOfSgnTypeElement.c b/src/core/libs/supl/asn-rrlp/SeqOfSgnTypeElement.c index 527dc2487..5e1318713 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfSgnTypeElement.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfSgnTypeElement.c @@ -14,10 +14,10 @@ static asn_per_constraints_t ASN_PER_TYPE_SEQ_OF_SGN_TYPE_ELEMENT_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_SeqOfSgnTypeElement_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_SgnTypeElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_SgnTypeElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfSgnTypeElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/SeqOfStandardClockModelElement.c b/src/core/libs/supl/asn-rrlp/SeqOfStandardClockModelElement.c index ff3243ed2..e76e6c139 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfStandardClockModelElement.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfStandardClockModelElement.c @@ -15,10 +15,10 @@ static asn_per_constraints_t }; static asn_TYPE_member_t asn_MBR_SeqOfStandardClockModelElement_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_StandardClockModelElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_StandardClockModelElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfStandardClockModelElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -43,7 +43,7 @@ asn_TYPE_descriptor_t asn_DEF_SeqOfStandardClockModelElement = { asn_DEF_SeqOfStandardClockModelElement_tags_1, sizeof(asn_DEF_SeqOfStandardClockModelElement_tags_1) / sizeof(asn_DEF_SeqOfStandardClockModelElement_tags_1[0]), /* 1 */ - asn_DEF_SeqOfStandardClockModelElement_tags_1, /* Same as above */ + asn_DEF_SeqOfStandardClockModelElement_tags_1, /* Same as above */ sizeof(asn_DEF_SeqOfStandardClockModelElement_tags_1) / sizeof(asn_DEF_SeqOfStandardClockModelElement_tags_1[0]), /* 1 */ &ASN_PER_TYPE_SEQ_OF_STANDARD_CLOCK_MODEL_ELEMENT_CONSTR_1, diff --git a/src/core/libs/supl/asn-rrlp/SeqOfSystemInfoAssistBTS-R98-ExpOTD.c b/src/core/libs/supl/asn-rrlp/SeqOfSystemInfoAssistBTS-R98-ExpOTD.c index 5138c29b4..1ad60c412 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfSystemInfoAssistBTS-R98-ExpOTD.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfSystemInfoAssistBTS-R98-ExpOTD.c @@ -15,10 +15,10 @@ static asn_per_constraints_t }; static asn_TYPE_member_t asn_MBR_SeqOfSystemInfoAssistBTS_R98_ExpOTD_1[] = { {ATF_POINTER, 0, 0, -1 /* Ambiguous tag (CHOICE?) */, 0, - &asn_DEF_SystemInfoAssistBTS_R98_ExpOTD, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_SystemInfoAssistBTS_R98_ExpOTD, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfSystemInfoAssistBTS_R98_ExpOTD_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -44,7 +44,7 @@ asn_TYPE_descriptor_t asn_DEF_SeqOfSystemInfoAssistBTS_R98_ExpOTD = { asn_DEF_SeqOfSystemInfoAssistBTS_R98_ExpOTD_tags_1, sizeof(asn_DEF_SeqOfSystemInfoAssistBTS_R98_ExpOTD_tags_1) / sizeof(asn_DEF_SeqOfSystemInfoAssistBTS_R98_ExpOTD_tags_1[0]), /* 1 */ - asn_DEF_SeqOfSystemInfoAssistBTS_R98_ExpOTD_tags_1, /* Same as above */ + asn_DEF_SeqOfSystemInfoAssistBTS_R98_ExpOTD_tags_1, /* Same as above */ sizeof(asn_DEF_SeqOfSystemInfoAssistBTS_R98_ExpOTD_tags_1) / sizeof(asn_DEF_SeqOfSystemInfoAssistBTS_R98_ExpOTD_tags_1[0]), /* 1 */ &ASN_PER_TYPE_SEQ_OF_SYSTEM_INFO_ASSIST_BTS_R98_EXP_OTD_CONSTR_1, diff --git a/src/core/libs/supl/asn-rrlp/SeqOfSystemInfoAssistBTS.c b/src/core/libs/supl/asn-rrlp/SeqOfSystemInfoAssistBTS.c index 673f95688..cfea238f7 100644 --- a/src/core/libs/supl/asn-rrlp/SeqOfSystemInfoAssistBTS.c +++ b/src/core/libs/supl/asn-rrlp/SeqOfSystemInfoAssistBTS.c @@ -15,10 +15,10 @@ static asn_per_constraints_t }; static asn_TYPE_member_t asn_MBR_SeqOfSystemInfoAssistBTS_1[] = { {ATF_POINTER, 0, 0, -1 /* Ambiguous tag (CHOICE?) */, 0, - &asn_DEF_SystemInfoAssistBTS, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_SystemInfoAssistBTS, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SeqOfSystemInfoAssistBTS_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/SgnTypeElement.c b/src/core/libs/supl/asn-rrlp/SgnTypeElement.c index 716ca2898..4e2a0c7b1 100644 --- a/src/core/libs/supl/asn-rrlp/SgnTypeElement.c +++ b/src/core/libs/supl/asn-rrlp/SgnTypeElement.c @@ -15,7 +15,7 @@ static int memb_ganssStatusHealth_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ static int memb_ganssStatusHealth_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -42,21 +42,21 @@ static asn_per_constraints_t ASN_PER_MEMB_GANSS_STATUS_HEALTH_CONSTR_3 = { }; static asn_TYPE_member_t asn_MBR_SgnTypeElement_1[] = { {ATF_POINTER, 1, offsetof(struct SgnTypeElement, ganssSignalID), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GANSSSignalID, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ganssSignalID"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GANSSSignalID, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ganssSignalID"}, {ATF_NOFLAGS, 0, offsetof(struct SgnTypeElement, ganssStatusHealth), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ganssStatusHealth_constraint_1, - &ASN_PER_MEMB_GANSS_STATUS_HEALTH_CONSTR_3, 0, "ganssStatusHealth"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ganssStatusHealth_constraint_1, + &ASN_PER_MEMB_GANSS_STATUS_HEALTH_CONSTR_3, 0, "ganssStatusHealth"}, {ATF_NOFLAGS, 0, offsetof(struct SgnTypeElement, dganssSgnList), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfDGANSSSgnElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "dganssSgnList"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfDGANSSSgnElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "dganssSgnList"}, }; static int asn_MAP_SgnTypeElement_oms_1[] = {0}; static ber_tlv_tag_t asn_DEF_SgnTypeElement_tags_1[] = { @@ -64,7 +64,7 @@ static ber_tlv_tag_t asn_DEF_SgnTypeElement_tags_1[] = { static asn_TYPE_tag2member_t asn_MAP_SgnTypeElement_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* ganssSignalID at 1196 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0}, /* ganssStatusHealth at 1197 */ + 0}, /* ganssStatusHealth at 1197 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0} /* dganssSgnList at 1200 */ }; static asn_SEQUENCE_specifics_t asn_SPC_SgnTypeElement_specs_1 = { @@ -97,7 +97,7 @@ asn_TYPE_descriptor_t asn_DEF_SgnTypeElement = { asn_DEF_SgnTypeElement_tags_1, /* Same as above */ sizeof(asn_DEF_SgnTypeElement_tags_1) / sizeof(asn_DEF_SgnTypeElement_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_SgnTypeElement_1, 3, /* Elements count */ &asn_SPC_SgnTypeElement_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/SgnTypeElement.h b/src/core/libs/supl/asn-rrlp/SgnTypeElement.h index 6e4bd8a15..ce5b54372 100644 --- a/src/core/libs/supl/asn-rrlp/SgnTypeElement.h +++ b/src/core/libs/supl/asn-rrlp/SgnTypeElement.h @@ -11,8 +11,8 @@ /* Including external dependencies */ #include "GANSSSignalID.h" -#include #include "SeqOfDGANSSSgnElement.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/StandardClockModelElement.c b/src/core/libs/supl/asn-rrlp/StandardClockModelElement.c index 82c5110bc..6507344fd 100644 --- a/src/core/libs/supl/asn-rrlp/StandardClockModelElement.c +++ b/src/core/libs/supl/asn-rrlp/StandardClockModelElement.c @@ -15,7 +15,7 @@ static int memb_stanClockTocLSB_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,22 +29,22 @@ static int memb_stanClockTocLSB_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_stanClockAF2_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -58,22 +58,22 @@ static int memb_stanClockAF2_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_stanClockAF1_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -87,22 +87,22 @@ static int memb_stanClockAF1_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_stanClockAF0_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -116,22 +116,22 @@ static int memb_stanClockAF0_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_stanClockTgd_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -145,22 +145,22 @@ static int memb_stanClockTgd_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_stanModelID_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -174,7 +174,7 @@ static int memb_stanModelID_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -199,7 +199,7 @@ static asn_per_constraints_t ASN_PER_MEMB_STAN_CLOCK_A_F1_CONSTR_4 = { }; static asn_per_constraints_t ASN_PER_MEMB_STAN_CLOCK_A_F0_CONSTR_5 = { {APC_CONSTRAINED, 28, -1, -134217728, - 134217727} /* (-134217728..134217727) */, + 134217727} /* (-134217728..134217727) */, {APC_UNCONSTRAINED, -1, -1, 0, 0}, 0, 0 /* No PER value map */ @@ -218,30 +218,30 @@ static asn_per_constraints_t ASN_PER_MEMB_STAN_MODEL_ID_CONSTR_7 = { }; static asn_TYPE_member_t asn_MBR_StandardClockModelElement_1[] = { {ATF_NOFLAGS, 0, - offsetof(struct StandardClockModelElement, stanClockTocLSB), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_stanClockTocLSB_constraint_1, - &ASN_PER_MEMB_STAN_CLOCK_TOC_LSB_CONSTR_2, 0, "stanClockTocLSB"}, + offsetof(struct StandardClockModelElement, stanClockTocLSB), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_stanClockTocLSB_constraint_1, + &ASN_PER_MEMB_STAN_CLOCK_TOC_LSB_CONSTR_2, 0, "stanClockTocLSB"}, {ATF_NOFLAGS, 0, offsetof(struct StandardClockModelElement, stanClockAF2), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_stanClockAF2_constraint_1, - &ASN_PER_MEMB_STAN_CLOCK_A_F2_CONSTR_3, 0, "stanClockAF2"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_stanClockAF2_constraint_1, + &ASN_PER_MEMB_STAN_CLOCK_A_F2_CONSTR_3, 0, "stanClockAF2"}, {ATF_NOFLAGS, 0, offsetof(struct StandardClockModelElement, stanClockAF1), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_stanClockAF1_constraint_1, - &ASN_PER_MEMB_STAN_CLOCK_A_F1_CONSTR_4, 0, "stanClockAF1"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_stanClockAF1_constraint_1, + &ASN_PER_MEMB_STAN_CLOCK_A_F1_CONSTR_4, 0, "stanClockAF1"}, {ATF_NOFLAGS, 0, offsetof(struct StandardClockModelElement, stanClockAF0), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_stanClockAF0_constraint_1, - &ASN_PER_MEMB_STAN_CLOCK_A_F0_CONSTR_5, 0, "stanClockAF0"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_stanClockAF0_constraint_1, + &ASN_PER_MEMB_STAN_CLOCK_A_F0_CONSTR_5, 0, "stanClockAF0"}, {ATF_POINTER, 2, offsetof(struct StandardClockModelElement, stanClockTgd), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_stanClockTgd_constraint_1, - &ASN_PER_MEMB_STAN_CLOCK_TGD_CONSTR_6, 0, "stanClockTgd"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_stanClockTgd_constraint_1, + &ASN_PER_MEMB_STAN_CLOCK_TGD_CONSTR_6, 0, "stanClockTgd"}, {ATF_POINTER, 1, offsetof(struct StandardClockModelElement, stanModelID), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_stanModelID_constraint_1, - &ASN_PER_MEMB_STAN_MODEL_ID_CONSTR_7, 0, "stanModelID"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_stanModelID_constraint_1, + &ASN_PER_MEMB_STAN_MODEL_ID_CONSTR_7, 0, "stanModelID"}, }; static int asn_MAP_StandardClockModelElement_oms_1[] = {4, 5}; static ber_tlv_tag_t asn_DEF_StandardClockModelElement_tags_1[] = { @@ -284,7 +284,7 @@ asn_TYPE_descriptor_t asn_DEF_StandardClockModelElement = { asn_DEF_StandardClockModelElement_tags_1, /* Same as above */ sizeof(asn_DEF_StandardClockModelElement_tags_1) / sizeof(asn_DEF_StandardClockModelElement_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_StandardClockModelElement_1, 6, /* Elements count */ &asn_SPC_StandardClockModelElement_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/StdResolution.c b/src/core/libs/supl/asn-rrlp/StdResolution.c index 739679862..97b7aee51 100644 --- a/src/core/libs/supl/asn-rrlp/StdResolution.c +++ b/src/core/libs/supl/asn-rrlp/StdResolution.c @@ -7,15 +7,15 @@ #include "StdResolution.h" int StdResolution_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ int StdResolution_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -56,74 +56,74 @@ static void StdResolution_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void StdResolution_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { StdResolution_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int StdResolution_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { StdResolution_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t StdResolution_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { StdResolution_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t StdResolution_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { StdResolution_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t StdResolution_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, const char *opt_mname, + const void *bufptr, size_t size) { StdResolution_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t StdResolution_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { StdResolution_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t StdResolution_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { StdResolution_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t StdResolution_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { StdResolution_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/SystemInfoAssistBTS-R98-ExpOTD.c b/src/core/libs/supl/asn-rrlp/SystemInfoAssistBTS-R98-ExpOTD.c index ca495403a..7b420a0b7 100644 --- a/src/core/libs/supl/asn-rrlp/SystemInfoAssistBTS-R98-ExpOTD.c +++ b/src/core/libs/supl/asn-rrlp/SystemInfoAssistBTS-R98-ExpOTD.c @@ -15,18 +15,18 @@ static asn_per_constraints_t }; static asn_TYPE_member_t asn_MBR_SystemInfoAssistBTS_R98_ExpOTD_1[] = { {ATF_NOFLAGS, 0, - offsetof(struct SystemInfoAssistBTS_R98_ExpOTD, choice.notPresent), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NULL, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "notPresent"}, + offsetof(struct SystemInfoAssistBTS_R98_ExpOTD, choice.notPresent), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NULL, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "notPresent"}, {ATF_NOFLAGS, 0, - offsetof(struct SystemInfoAssistBTS_R98_ExpOTD, choice.present), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_AssistBTSData_R98_ExpOTD, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "present"}, + offsetof(struct SystemInfoAssistBTS_R98_ExpOTD, choice.present), + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_AssistBTSData_R98_ExpOTD, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "present"}, }; static asn_TYPE_tag2member_t asn_MAP_SystemInfoAssistBTS_R98_ExpOTD_tag2el_1[] = { diff --git a/src/core/libs/supl/asn-rrlp/SystemInfoAssistBTS-R98-ExpOTD.h b/src/core/libs/supl/asn-rrlp/SystemInfoAssistBTS-R98-ExpOTD.h index fd389ee03..944ac80aa 100644 --- a/src/core/libs/supl/asn-rrlp/SystemInfoAssistBTS-R98-ExpOTD.h +++ b/src/core/libs/supl/asn-rrlp/SystemInfoAssistBTS-R98-ExpOTD.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include #include "AssistBTSData-R98-ExpOTD.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/SystemInfoAssistBTS.c b/src/core/libs/supl/asn-rrlp/SystemInfoAssistBTS.c index a0875af9e..2a2f10811 100644 --- a/src/core/libs/supl/asn-rrlp/SystemInfoAssistBTS.c +++ b/src/core/libs/supl/asn-rrlp/SystemInfoAssistBTS.c @@ -14,16 +14,16 @@ static asn_per_constraints_t ASN_PER_TYPE_SYSTEM_INFO_ASSIST_BTS_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_SystemInfoAssistBTS_1[] = { {ATF_NOFLAGS, 0, offsetof(struct SystemInfoAssistBTS, choice.notPresent), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NULL, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "notPresent"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NULL, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "notPresent"}, {ATF_NOFLAGS, 0, offsetof(struct SystemInfoAssistBTS, choice.present), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_AssistBTSData, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "present"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_AssistBTSData, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "present"}, }; static asn_TYPE_tag2member_t asn_MAP_SystemInfoAssistBTS_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* notPresent at 223 */ diff --git a/src/core/libs/supl/asn-rrlp/SystemInfoAssistBTS.h b/src/core/libs/supl/asn-rrlp/SystemInfoAssistBTS.h index 5eecf4a9d..7705e2f55 100644 --- a/src/core/libs/supl/asn-rrlp/SystemInfoAssistBTS.h +++ b/src/core/libs/supl/asn-rrlp/SystemInfoAssistBTS.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include #include "AssistBTSData.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/SystemInfoAssistData-R98-ExpOTD.c b/src/core/libs/supl/asn-rrlp/SystemInfoAssistData-R98-ExpOTD.c index 12690aba2..196c3c5c0 100644 --- a/src/core/libs/supl/asn-rrlp/SystemInfoAssistData-R98-ExpOTD.c +++ b/src/core/libs/supl/asn-rrlp/SystemInfoAssistData-R98-ExpOTD.c @@ -8,20 +8,20 @@ static asn_TYPE_member_t asn_MBR_SystemInfoAssistData_R98_ExpOTD_1[] = { {ATF_NOFLAGS, 0, - offsetof(struct SystemInfoAssistData_R98_ExpOTD, - systemInfoAssistListR98_ExpOTD), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfSystemInfoAssistBTS_R98_ExpOTD, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "systemInfoAssistListR98-ExpOTD"}, + offsetof(struct SystemInfoAssistData_R98_ExpOTD, + systemInfoAssistListR98_ExpOTD), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfSystemInfoAssistBTS_R98_ExpOTD, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "systemInfoAssistListR98-ExpOTD"}, }; static ber_tlv_tag_t asn_DEF_SystemInfoAssistData_R98_ExpOTD_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_SystemInfoAssistData_R98_ExpOTD_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0} /* systemInfoAssistListR98-ExpOTD at 917 */ + 0} /* systemInfoAssistListR98-ExpOTD at 917 */ }; static asn_SEQUENCE_specifics_t asn_SPC_SystemInfoAssistData_R98_ExpOTD_specs_1 = { @@ -51,10 +51,10 @@ asn_TYPE_descriptor_t asn_DEF_SystemInfoAssistData_R98_ExpOTD = { asn_DEF_SystemInfoAssistData_R98_ExpOTD_tags_1, sizeof(asn_DEF_SystemInfoAssistData_R98_ExpOTD_tags_1) / sizeof(asn_DEF_SystemInfoAssistData_R98_ExpOTD_tags_1[0]), /* 1 */ - asn_DEF_SystemInfoAssistData_R98_ExpOTD_tags_1, /* Same as above */ + asn_DEF_SystemInfoAssistData_R98_ExpOTD_tags_1, /* Same as above */ sizeof(asn_DEF_SystemInfoAssistData_R98_ExpOTD_tags_1) / sizeof(asn_DEF_SystemInfoAssistData_R98_ExpOTD_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_SystemInfoAssistData_R98_ExpOTD_1, 1, /* Elements count */ &asn_SPC_SystemInfoAssistData_R98_ExpOTD_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/SystemInfoAssistData.c b/src/core/libs/supl/asn-rrlp/SystemInfoAssistData.c index 1a1bd263b..8136c57f2 100644 --- a/src/core/libs/supl/asn-rrlp/SystemInfoAssistData.c +++ b/src/core/libs/supl/asn-rrlp/SystemInfoAssistData.c @@ -8,18 +8,18 @@ static asn_TYPE_member_t asn_MBR_SystemInfoAssistData_1[] = { {ATF_NOFLAGS, 0, - offsetof(struct SystemInfoAssistData, systemInfoAssistList), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SeqOfSystemInfoAssistBTS, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "systemInfoAssistList"}, + offsetof(struct SystemInfoAssistData, systemInfoAssistList), + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SeqOfSystemInfoAssistBTS, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "systemInfoAssistList"}, }; static ber_tlv_tag_t asn_DEF_SystemInfoAssistData_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_SystemInfoAssistData_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0} /* systemInfoAssistList at 218 */ + 0} /* systemInfoAssistList at 218 */ }; static asn_SEQUENCE_specifics_t asn_SPC_SystemInfoAssistData_specs_1 = { sizeof(struct SystemInfoAssistData), @@ -51,7 +51,7 @@ asn_TYPE_descriptor_t asn_DEF_SystemInfoAssistData = { asn_DEF_SystemInfoAssistData_tags_1, /* Same as above */ sizeof(asn_DEF_SystemInfoAssistData_tags_1) / sizeof(asn_DEF_SystemInfoAssistData_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_SystemInfoAssistData_1, 1, /* Elements count */ &asn_SPC_SystemInfoAssistData_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/SystemInfoIndex.c b/src/core/libs/supl/asn-rrlp/SystemInfoIndex.c index 3118488ff..45781f7df 100644 --- a/src/core/libs/supl/asn-rrlp/SystemInfoIndex.c +++ b/src/core/libs/supl/asn-rrlp/SystemInfoIndex.c @@ -7,15 +7,15 @@ #include "SystemInfoIndex.h" int SystemInfoIndex_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ int SystemInfoIndex_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -56,76 +56,76 @@ static void SystemInfoIndex_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void SystemInfoIndex_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { SystemInfoIndex_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int SystemInfoIndex_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, + void *app_key) { SystemInfoIndex_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t SystemInfoIndex_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { SystemInfoIndex_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t SystemInfoIndex_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { SystemInfoIndex_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t SystemInfoIndex_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { SystemInfoIndex_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t SystemInfoIndex_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { SystemInfoIndex_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t SystemInfoIndex_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { SystemInfoIndex_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t SystemInfoIndex_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { SystemInfoIndex_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/TA0.c b/src/core/libs/supl/asn-rrlp/TA0.c index d737478a5..8237d961c 100644 --- a/src/core/libs/supl/asn-rrlp/TA0.c +++ b/src/core/libs/supl/asn-rrlp/TA0.c @@ -7,14 +7,14 @@ #include "TA0.h" int TA0_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int TA0_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -61,60 +61,60 @@ void TA0_free(asn_TYPE_descriptor_t *td, void *struct_ptr, int contents_only) } int TA0_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { TA0_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t TA0_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, int tag_mode) { TA0_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t TA0_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { TA0_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t TA0_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { TA0_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t TA0_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { TA0_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t TA0_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { TA0_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t TA0_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { TA0_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); @@ -122,7 +122,7 @@ asn_enc_rval_t TA0_encode_uper(asn_TYPE_descriptor_t *td, static asn_per_constraints_t ASN_PER_TYPE_T_A0_CONSTR_1 = { {APC_CONSTRAINED, 32, -1, (-2147483647L - 1), - 2147483647} /* (-2147483648..2147483647) */, + 2147483647} /* (-2147483648..2147483647) */, {APC_UNCONSTRAINED, -1, -1, 0, 0}, 0, 0 /* No PER value map */ @@ -144,7 +144,7 @@ asn_TYPE_descriptor_t asn_DEF_TA0 = { 0, /* Use generic outmost tag fetcher */ asn_DEF_TA0_tags_1, sizeof(asn_DEF_TA0_tags_1) / sizeof(asn_DEF_TA0_tags_1[0]), /* 1 */ - asn_DEF_TA0_tags_1, /* Same as above */ + asn_DEF_TA0_tags_1, /* Same as above */ sizeof(asn_DEF_TA0_tags_1) / sizeof(asn_DEF_TA0_tags_1[0]), /* 1 */ &ASN_PER_TYPE_T_A0_CONSTR_1, 0, diff --git a/src/core/libs/supl/asn-rrlp/TA1.c b/src/core/libs/supl/asn-rrlp/TA1.c index 5ee4dda82..3b79d5d62 100644 --- a/src/core/libs/supl/asn-rrlp/TA1.c +++ b/src/core/libs/supl/asn-rrlp/TA1.c @@ -7,14 +7,14 @@ #include "TA1.h" int TA1_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int TA1_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -61,60 +61,60 @@ void TA1_free(asn_TYPE_descriptor_t *td, void *struct_ptr, int contents_only) } int TA1_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { TA1_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t TA1_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, int tag_mode) { TA1_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t TA1_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { TA1_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t TA1_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { TA1_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t TA1_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { TA1_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t TA1_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { TA1_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t TA1_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { TA1_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); @@ -143,7 +143,7 @@ asn_TYPE_descriptor_t asn_DEF_TA1 = { 0, /* Use generic outmost tag fetcher */ asn_DEF_TA1_tags_1, sizeof(asn_DEF_TA1_tags_1) / sizeof(asn_DEF_TA1_tags_1[0]), /* 1 */ - asn_DEF_TA1_tags_1, /* Same as above */ + asn_DEF_TA1_tags_1, /* Same as above */ sizeof(asn_DEF_TA1_tags_1) / sizeof(asn_DEF_TA1_tags_1[0]), /* 1 */ &ASN_PER_TYPE_T_A1_CONSTR_1, 0, diff --git a/src/core/libs/supl/asn-rrlp/TA2.c b/src/core/libs/supl/asn-rrlp/TA2.c index 7ef77bfb0..8eb79b9c3 100644 --- a/src/core/libs/supl/asn-rrlp/TA2.c +++ b/src/core/libs/supl/asn-rrlp/TA2.c @@ -7,14 +7,14 @@ #include "TA2.h" int TA2_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int TA2_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -61,60 +61,60 @@ void TA2_free(asn_TYPE_descriptor_t *td, void *struct_ptr, int contents_only) } int TA2_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { TA2_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t TA2_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, int tag_mode) { TA2_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t TA2_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { TA2_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t TA2_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { TA2_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t TA2_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { TA2_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t TA2_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { TA2_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t TA2_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { TA2_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); @@ -143,7 +143,7 @@ asn_TYPE_descriptor_t asn_DEF_TA2 = { 0, /* Use generic outmost tag fetcher */ asn_DEF_TA2_tags_1, sizeof(asn_DEF_TA2_tags_1) / sizeof(asn_DEF_TA2_tags_1[0]), /* 1 */ - asn_DEF_TA2_tags_1, /* Same as above */ + asn_DEF_TA2_tags_1, /* Same as above */ sizeof(asn_DEF_TA2_tags_1) / sizeof(asn_DEF_TA2_tags_1[0]), /* 1 */ &ASN_PER_TYPE_T_A2_CONSTR_1, 0, diff --git a/src/core/libs/supl/asn-rrlp/TLMReservedBits.c b/src/core/libs/supl/asn-rrlp/TLMReservedBits.c index c435355ab..31c70e6aa 100644 --- a/src/core/libs/supl/asn-rrlp/TLMReservedBits.c +++ b/src/core/libs/supl/asn-rrlp/TLMReservedBits.c @@ -7,15 +7,15 @@ #include "TLMReservedBits.h" int TLMReservedBits_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ int TLMReservedBits_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -56,76 +56,76 @@ static void TLMReservedBits_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void TLMReservedBits_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { TLMReservedBits_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int TLMReservedBits_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, + void *app_key) { TLMReservedBits_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t TLMReservedBits_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { TLMReservedBits_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t TLMReservedBits_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { TLMReservedBits_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t TLMReservedBits_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { TLMReservedBits_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t TLMReservedBits_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { TLMReservedBits_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t TLMReservedBits_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { TLMReservedBits_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t TLMReservedBits_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { TLMReservedBits_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/TLMWord.c b/src/core/libs/supl/asn-rrlp/TLMWord.c index b8e5b6d4f..99e621b23 100644 --- a/src/core/libs/supl/asn-rrlp/TLMWord.c +++ b/src/core/libs/supl/asn-rrlp/TLMWord.c @@ -7,14 +7,14 @@ #include "TLMWord.h" int TLMWord_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int TLMWord_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -55,67 +55,67 @@ static void TLMWord_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void TLMWord_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { TLMWord_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int TLMWord_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { TLMWord_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t TLMWord_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, int tag_mode) { TLMWord_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t TLMWord_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { TLMWord_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t TLMWord_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { TLMWord_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t TLMWord_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { TLMWord_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t TLMWord_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { TLMWord_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t TLMWord_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { TLMWord_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); @@ -144,7 +144,7 @@ asn_TYPE_descriptor_t asn_DEF_TLMWord = { 0, /* Use generic outmost tag fetcher */ asn_DEF_TLMWord_tags_1, sizeof(asn_DEF_TLMWord_tags_1) / sizeof(asn_DEF_TLMWord_tags_1[0]), /* 1 */ - asn_DEF_TLMWord_tags_1, /* Same as above */ + asn_DEF_TLMWord_tags_1, /* Same as above */ sizeof(asn_DEF_TLMWord_tags_1) / sizeof(asn_DEF_TLMWord_tags_1[0]), /* 1 */ &ASN_PER_TYPE_TLM_WORD_CONSTR_1, 0, diff --git a/src/core/libs/supl/asn-rrlp/TOA-MeasurementsOfRef.c b/src/core/libs/supl/asn-rrlp/TOA-MeasurementsOfRef.c index bc7c61c61..c330a5d76 100644 --- a/src/core/libs/supl/asn-rrlp/TOA-MeasurementsOfRef.c +++ b/src/core/libs/supl/asn-rrlp/TOA-MeasurementsOfRef.c @@ -8,22 +8,22 @@ static asn_TYPE_member_t asn_MBR_TOA_MeasurementsOfRef_1[] = { {ATF_NOFLAGS, 0, offsetof(struct TOA_MeasurementsOfRef, refQuality), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_RefQuality, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "refQuality"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_RefQuality, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "refQuality"}, {ATF_NOFLAGS, 0, offsetof(struct TOA_MeasurementsOfRef, numOfMeasurements), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NumOfMeasurements, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "numOfMeasurements"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NumOfMeasurements, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "numOfMeasurements"}, }; static ber_tlv_tag_t asn_DEF_TOA_MeasurementsOfRef_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_TOA_MeasurementsOfRef_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* refQuality at 360 */ - {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0} /* numOfMeasurements at 362 */ + {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0} /* numOfMeasurements at 362 */ }; static asn_SEQUENCE_specifics_t asn_SPC_TOA_MeasurementsOfRef_specs_1 = { sizeof(struct TOA_MeasurementsOfRef), @@ -55,7 +55,7 @@ asn_TYPE_descriptor_t asn_DEF_TOA_MeasurementsOfRef = { asn_DEF_TOA_MeasurementsOfRef_tags_1, /* Same as above */ sizeof(asn_DEF_TOA_MeasurementsOfRef_tags_1) / sizeof(asn_DEF_TOA_MeasurementsOfRef_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_TOA_MeasurementsOfRef_1, 2, /* Elements count */ &asn_SPC_TOA_MeasurementsOfRef_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/TOA-MeasurementsOfRef.h b/src/core/libs/supl/asn-rrlp/TOA-MeasurementsOfRef.h index 3f54b3cdf..e7e864497 100644 --- a/src/core/libs/supl/asn-rrlp/TOA-MeasurementsOfRef.h +++ b/src/core/libs/supl/asn-rrlp/TOA-MeasurementsOfRef.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include "RefQuality.h" #include "NumOfMeasurements.h" +#include "RefQuality.h" #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/TimeRelation.c b/src/core/libs/supl/asn-rrlp/TimeRelation.c index a5e751cd8..477b650d6 100644 --- a/src/core/libs/supl/asn-rrlp/TimeRelation.c +++ b/src/core/libs/supl/asn-rrlp/TimeRelation.c @@ -8,15 +8,15 @@ static asn_TYPE_member_t asn_MBR_TimeRelation_1[] = { {ATF_NOFLAGS, 0, offsetof(struct TimeRelation, gpsTOW), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GPSTOW23b, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "gpsTOW"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GPSTOW23b, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "gpsTOW"}, {ATF_POINTER, 1, offsetof(struct TimeRelation, gsmTime), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GSMTime, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "gsmTime"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GSMTime, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "gsmTime"}, }; static int asn_MAP_TimeRelation_oms_1[] = {1}; static ber_tlv_tag_t asn_DEF_TimeRelation_tags_1[] = { diff --git a/src/core/libs/supl/asn-rrlp/TimeSlot.c b/src/core/libs/supl/asn-rrlp/TimeSlot.c index b155af70f..6aae7e251 100644 --- a/src/core/libs/supl/asn-rrlp/TimeSlot.c +++ b/src/core/libs/supl/asn-rrlp/TimeSlot.c @@ -7,14 +7,14 @@ #include "TimeSlot.h" int TimeSlot_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int TimeSlot_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -55,68 +55,68 @@ static void TimeSlot_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void TimeSlot_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { TimeSlot_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int TimeSlot_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { TimeSlot_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t TimeSlot_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, + int tag_mode) { TimeSlot_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t TimeSlot_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { TimeSlot_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t TimeSlot_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { TimeSlot_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t TimeSlot_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { TimeSlot_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t TimeSlot_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { TimeSlot_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t TimeSlot_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { TimeSlot_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/TimeSlotScheme.c b/src/core/libs/supl/asn-rrlp/TimeSlotScheme.c index 0538187ab..637b3ab16 100644 --- a/src/core/libs/supl/asn-rrlp/TimeSlotScheme.c +++ b/src/core/libs/supl/asn-rrlp/TimeSlotScheme.c @@ -7,8 +7,8 @@ #include "TimeSlotScheme.h" int TimeSlotScheme_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { /* Replace with underlying type checker */ td->check_constraints = asn_DEF_ENUMERATED.check_constraints; @@ -39,75 +39,75 @@ static void TimeSlotScheme_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void TimeSlotScheme_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { TimeSlotScheme_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int TimeSlotScheme_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { TimeSlotScheme_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t TimeSlotScheme_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { TimeSlotScheme_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t TimeSlotScheme_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { TimeSlotScheme_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t TimeSlotScheme_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { TimeSlotScheme_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t TimeSlotScheme_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { TimeSlotScheme_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t TimeSlotScheme_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { TimeSlotScheme_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t TimeSlotScheme_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { TimeSlotScheme_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/UTCModel.c b/src/core/libs/supl/asn-rrlp/UTCModel.c index a2bcd79d3..175a6842c 100644 --- a/src/core/libs/supl/asn-rrlp/UTCModel.c +++ b/src/core/libs/supl/asn-rrlp/UTCModel.c @@ -7,15 +7,15 @@ #include "UTCModel.h" static int memb_utcA1_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,21 +29,21 @@ static int memb_utcA1_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_utcA0_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -57,21 +57,21 @@ static int memb_utcA0_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_utcTot_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -85,21 +85,21 @@ static int memb_utcTot_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_utcWNt_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -113,22 +113,22 @@ static int memb_utcWNt_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_utcDeltaTls_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -142,22 +142,22 @@ static int memb_utcDeltaTls_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_utcWNlsf_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -171,21 +171,21 @@ static int memb_utcWNlsf_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_utcDN_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -199,22 +199,22 @@ static int memb_utcDN_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_utcDeltaTlsf_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -228,7 +228,7 @@ static int memb_utcDeltaTlsf_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -241,7 +241,7 @@ static asn_per_constraints_t ASN_PER_MEMB_UTC_A1_CONSTR_2 = { }; static asn_per_constraints_t ASN_PER_MEMB_UTC_A0_CONSTR_3 = { {APC_CONSTRAINED, 32, -1, (-2147483647L - 1), - 2147483647} /* (-2147483648..2147483647) */, + 2147483647} /* (-2147483648..2147483647) */, {APC_UNCONSTRAINED, -1, -1, 0, 0}, 0, 0 /* No PER value map */ @@ -284,37 +284,37 @@ static asn_per_constraints_t ASN_PER_MEMB_UTC_DELTA_TLSF_CONSTR_9 = { }; static asn_TYPE_member_t asn_MBR_UTCModel_1[] = { {ATF_NOFLAGS, 0, offsetof(struct UTCModel, utcA1), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_utcA1_constraint_1, - &ASN_PER_MEMB_UTC_A1_CONSTR_2, 0, "utcA1"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_utcA1_constraint_1, + &ASN_PER_MEMB_UTC_A1_CONSTR_2, 0, "utcA1"}, {ATF_NOFLAGS, 0, offsetof(struct UTCModel, utcA0), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_utcA0_constraint_1, - &ASN_PER_MEMB_UTC_A0_CONSTR_3, 0, "utcA0"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_utcA0_constraint_1, + &ASN_PER_MEMB_UTC_A0_CONSTR_3, 0, "utcA0"}, {ATF_NOFLAGS, 0, offsetof(struct UTCModel, utcTot), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_utcTot_constraint_1, - &ASN_PER_MEMB_UTC_TOT_CONSTR_4, 0, "utcTot"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_utcTot_constraint_1, + &ASN_PER_MEMB_UTC_TOT_CONSTR_4, 0, "utcTot"}, {ATF_NOFLAGS, 0, offsetof(struct UTCModel, utcWNt), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_utcWNt_constraint_1, - &ASN_PER_MEMB_UTC_W_NT_CONSTR_5, 0, "utcWNt"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_utcWNt_constraint_1, + &ASN_PER_MEMB_UTC_W_NT_CONSTR_5, 0, "utcWNt"}, {ATF_NOFLAGS, 0, offsetof(struct UTCModel, utcDeltaTls), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_utcDeltaTls_constraint_1, - &ASN_PER_MEMB_UTC_DELTA_TLS_CONSTR_6, 0, "utcDeltaTls"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_utcDeltaTls_constraint_1, + &ASN_PER_MEMB_UTC_DELTA_TLS_CONSTR_6, 0, "utcDeltaTls"}, {ATF_NOFLAGS, 0, offsetof(struct UTCModel, utcWNlsf), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_utcWNlsf_constraint_1, - &ASN_PER_MEMB_UTC_W_NLSF_CONSTR_7, 0, "utcWNlsf"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_utcWNlsf_constraint_1, + &ASN_PER_MEMB_UTC_W_NLSF_CONSTR_7, 0, "utcWNlsf"}, {ATF_NOFLAGS, 0, offsetof(struct UTCModel, utcDN), - (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_utcDN_constraint_1, - &ASN_PER_MEMB_UTC_DN_CONSTR_8, 0, "utcDN"}, + (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_utcDN_constraint_1, + &ASN_PER_MEMB_UTC_DN_CONSTR_8, 0, "utcDN"}, {ATF_NOFLAGS, 0, offsetof(struct UTCModel, utcDeltaTlsf), - (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_utcDeltaTlsf_constraint_1, - &ASN_PER_MEMB_UTC_DELTA_TLSF_CONSTR_9, 0, "utcDeltaTlsf"}, + (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_utcDeltaTlsf_constraint_1, + &ASN_PER_MEMB_UTC_DELTA_TLSF_CONSTR_9, 0, "utcDeltaTlsf"}, }; static ber_tlv_tag_t asn_DEF_UTCModel_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-rrlp/UlPseudoSegInd.c b/src/core/libs/supl/asn-rrlp/UlPseudoSegInd.c index c87a76643..e72f0f994 100644 --- a/src/core/libs/supl/asn-rrlp/UlPseudoSegInd.c +++ b/src/core/libs/supl/asn-rrlp/UlPseudoSegInd.c @@ -7,8 +7,8 @@ #include "UlPseudoSegInd.h" int UlPseudoSegInd_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { /* Replace with underlying type checker */ td->check_constraints = asn_DEF_ENUMERATED.check_constraints; @@ -39,75 +39,75 @@ static void UlPseudoSegInd_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void UlPseudoSegInd_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { UlPseudoSegInd_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int UlPseudoSegInd_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { UlPseudoSegInd_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t UlPseudoSegInd_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { UlPseudoSegInd_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t UlPseudoSegInd_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { UlPseudoSegInd_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t UlPseudoSegInd_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { UlPseudoSegInd_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t UlPseudoSegInd_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { UlPseudoSegInd_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t UlPseudoSegInd_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { UlPseudoSegInd_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t UlPseudoSegInd_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { UlPseudoSegInd_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/UncompressedEphemeris.c b/src/core/libs/supl/asn-rrlp/UncompressedEphemeris.c index b9e6f5061..2dfb1fb8c 100644 --- a/src/core/libs/supl/asn-rrlp/UncompressedEphemeris.c +++ b/src/core/libs/supl/asn-rrlp/UncompressedEphemeris.c @@ -7,15 +7,15 @@ #include "UncompressedEphemeris.h" static int ephemE_17_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { unsigned long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -48,92 +48,92 @@ static void ephemE_17_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } static void ephemE_17_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { ephemE_17_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } static int ephemE_17_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, + void *app_key) { ephemE_17_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } static asn_dec_rval_t ephemE_17_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { ephemE_17_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } static asn_enc_rval_t ephemE_17_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { ephemE_17_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } static asn_dec_rval_t ephemE_17_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { ephemE_17_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } static asn_enc_rval_t ephemE_17_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { ephemE_17_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } static asn_dec_rval_t ephemE_17_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { ephemE_17_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } static asn_enc_rval_t ephemE_17_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { ephemE_17_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); } static int ephemAPowerHalf_19_constraint(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { unsigned long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -167,15 +167,15 @@ static void ephemAPowerHalf_19_inherit_TYPE_descriptor( } static void ephemAPowerHalf_19_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { ephemAPowerHalf_19_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } static int ephemAPowerHalf_19_print(asn_TYPE_descriptor_t *td, - const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + const void *struct_ptr, int ilevel, + asn_app_consume_bytes_f *cb, void *app_key) { ephemAPowerHalf_19_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); @@ -187,7 +187,7 @@ static asn_dec_rval_t ephemAPowerHalf_19_decode_ber( { ephemAPowerHalf_19_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } static asn_enc_rval_t ephemAPowerHalf_19_encode_der( @@ -204,7 +204,7 @@ static asn_dec_rval_t ephemAPowerHalf_19_decode_xer( { ephemAPowerHalf_19_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } static asn_enc_rval_t ephemAPowerHalf_19_encode_xer( @@ -222,7 +222,7 @@ static asn_dec_rval_t ephemAPowerHalf_19_decode_uper( { ephemAPowerHalf_19_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } static asn_enc_rval_t ephemAPowerHalf_19_encode_uper( @@ -242,7 +242,7 @@ static int memb_ephemCodeOnL2_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -256,22 +256,22 @@ static int memb_ephemCodeOnL2_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ephemURA_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -285,7 +285,7 @@ static int memb_ephemURA_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -299,7 +299,7 @@ static int memb_ephemSVhealth_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -313,22 +313,22 @@ static int memb_ephemSVhealth_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ephemIODC_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -342,22 +342,22 @@ static int memb_ephemIODC_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ephemL2Pflag_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -371,22 +371,22 @@ static int memb_ephemL2Pflag_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ephemTgd_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -400,22 +400,22 @@ static int memb_ephemTgd_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ephemToc_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -429,22 +429,22 @@ static int memb_ephemToc_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ephemAF2_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -458,22 +458,22 @@ static int memb_ephemAF2_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ephemAF1_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -487,22 +487,22 @@ static int memb_ephemAF1_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ephemAF0_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -516,22 +516,22 @@ static int memb_ephemAF0_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ephemCrs_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -545,22 +545,22 @@ static int memb_ephemCrs_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ephemDeltaN_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -574,22 +574,22 @@ static int memb_ephemDeltaN_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ephemM0_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -603,22 +603,22 @@ static int memb_ephemM0_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ephemCuc_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -632,21 +632,21 @@ static int memb_ephemCuc_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ephemE_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { unsigned long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -657,16 +657,16 @@ static int memb_ephemE_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, } static int memb_ephemCus_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -680,7 +680,7 @@ static int memb_ephemCus_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -694,7 +694,7 @@ static int memb_ephemAPowerHalf_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -705,16 +705,16 @@ static int memb_ephemAPowerHalf_constraint_1( } static int memb_ephemToe_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -728,22 +728,22 @@ static int memb_ephemToe_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ephemFitFlag_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -757,22 +757,22 @@ static int memb_ephemFitFlag_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ephemAODA_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -786,22 +786,22 @@ static int memb_ephemAODA_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ephemCic_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -815,22 +815,22 @@ static int memb_ephemCic_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ephemOmegaA0_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -844,22 +844,22 @@ static int memb_ephemOmegaA0_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ephemCis_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -873,22 +873,22 @@ static int memb_ephemCis_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ephemI0_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -902,22 +902,22 @@ static int memb_ephemI0_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ephemCrc_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -931,21 +931,21 @@ static int memb_ephemCrc_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ephemW_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -959,7 +959,7 @@ static int memb_ephemW_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -973,7 +973,7 @@ static int memb_ephemOmegaADot_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -987,22 +987,22 @@ static int memb_ephemOmegaADot_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ephemIDot_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -1016,7 +1016,7 @@ static int memb_ephemIDot_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -1107,7 +1107,7 @@ static asn_per_constraints_t ASN_PER_MEMB_EPHEM_DELTA_N_CONSTR_14 = { }; static asn_per_constraints_t ASN_PER_MEMB_EPHEM_M0_CONSTR_15 = { {APC_CONSTRAINED, 32, -1, (-2147483647L - 1), - 2147483647} /* (-2147483648..2147483647) */, + 2147483647} /* (-2147483648..2147483647) */, {APC_UNCONSTRAINED, -1, -1, 0, 0}, 0, 0 /* No PER value map */ @@ -1162,7 +1162,7 @@ static asn_per_constraints_t ASN_PER_MEMB_EPHEM_CIC_CONSTR_23 = { }; static asn_per_constraints_t ASN_PER_MEMB_EPHEM_OMEGA_A0_CONSTR_24 = { {APC_CONSTRAINED, 32, -1, (-2147483647L - 1), - 2147483647} /* (-2147483648..2147483647) */, + 2147483647} /* (-2147483648..2147483647) */, {APC_UNCONSTRAINED, -1, -1, 0, 0}, 0, 0 /* No PER value map */ @@ -1175,7 +1175,7 @@ static asn_per_constraints_t ASN_PER_MEMB_EPHEM_CIS_CONSTR_25 = { }; static asn_per_constraints_t ASN_PER_MEMB_EPHEM_I0_CONSTR_26 = { {APC_CONSTRAINED, 32, -1, (-2147483647L - 1), - 2147483647} /* (-2147483648..2147483647) */, + 2147483647} /* (-2147483648..2147483647) */, {APC_UNCONSTRAINED, -1, -1, 0, 0}, 0, 0 /* No PER value map */ @@ -1188,7 +1188,7 @@ static asn_per_constraints_t ASN_PER_MEMB_EPHEM_CRC_CONSTR_27 = { }; static asn_per_constraints_t ASN_PER_MEMB_EPHEM_W_CONSTR_28 = { {APC_CONSTRAINED, 32, -1, (-2147483647L - 1), - 2147483647} /* (-2147483648..2147483647) */, + 2147483647} /* (-2147483648..2147483647) */, {APC_UNCONSTRAINED, -1, -1, 0, 0}, 0, 0 /* No PER value map */ @@ -1272,142 +1272,142 @@ static /* Use -fall-defs-global to expose */ static asn_TYPE_member_t asn_MBR_UncompressedEphemeris_1[] = { {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemCodeOnL2), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemCodeOnL2_constraint_1, - &ASN_PER_MEMB_EPHEM_CODE_ON_L2_CONSTR_2, 0, "ephemCodeOnL2"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemCodeOnL2_constraint_1, + &ASN_PER_MEMB_EPHEM_CODE_ON_L2_CONSTR_2, 0, "ephemCodeOnL2"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemURA), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemURA_constraint_1, - &ASN_PER_MEMB_EPHEM_URA_CONSTR_3, 0, "ephemURA"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemURA_constraint_1, + &ASN_PER_MEMB_EPHEM_URA_CONSTR_3, 0, "ephemURA"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemSVhealth), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemSVhealth_constraint_1, - &ASN_PER_MEMB_EPHEM_S_VHEALTH_CONSTR_4, 0, "ephemSVhealth"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemSVhealth_constraint_1, + &ASN_PER_MEMB_EPHEM_S_VHEALTH_CONSTR_4, 0, "ephemSVhealth"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemIODC), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemIODC_constraint_1, - &ASN_PER_MEMB_EPHEM_IODC_CONSTR_5, 0, "ephemIODC"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemIODC_constraint_1, + &ASN_PER_MEMB_EPHEM_IODC_CONSTR_5, 0, "ephemIODC"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemL2Pflag), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemL2Pflag_constraint_1, - &ASN_PER_MEMB_EPHEM_L2_PFLAG_CONSTR_6, 0, "ephemL2Pflag"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemL2Pflag_constraint_1, + &ASN_PER_MEMB_EPHEM_L2_PFLAG_CONSTR_6, 0, "ephemL2Pflag"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemSF1Rsvd), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_EphemerisSubframe1Reserved, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ephemSF1Rsvd"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_EphemerisSubframe1Reserved, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ephemSF1Rsvd"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemTgd), - (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemTgd_constraint_1, - &ASN_PER_MEMB_EPHEM_TGD_CONSTR_8, 0, "ephemTgd"}, + (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemTgd_constraint_1, + &ASN_PER_MEMB_EPHEM_TGD_CONSTR_8, 0, "ephemTgd"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemToc), - (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemToc_constraint_1, - &ASN_PER_MEMB_EPHEM_TOC_CONSTR_9, 0, "ephemToc"}, + (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemToc_constraint_1, + &ASN_PER_MEMB_EPHEM_TOC_CONSTR_9, 0, "ephemToc"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemAF2), - (ASN_TAG_CLASS_CONTEXT | (8 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemAF2_constraint_1, - &ASN_PER_MEMB_EPHEM_A_F2_CONSTR_10, 0, "ephemAF2"}, + (ASN_TAG_CLASS_CONTEXT | (8 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemAF2_constraint_1, + &ASN_PER_MEMB_EPHEM_A_F2_CONSTR_10, 0, "ephemAF2"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemAF1), - (ASN_TAG_CLASS_CONTEXT | (9 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemAF1_constraint_1, - &ASN_PER_MEMB_EPHEM_A_F1_CONSTR_11, 0, "ephemAF1"}, + (ASN_TAG_CLASS_CONTEXT | (9 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemAF1_constraint_1, + &ASN_PER_MEMB_EPHEM_A_F1_CONSTR_11, 0, "ephemAF1"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemAF0), - (ASN_TAG_CLASS_CONTEXT | (10 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemAF0_constraint_1, - &ASN_PER_MEMB_EPHEM_A_F0_CONSTR_12, 0, "ephemAF0"}, + (ASN_TAG_CLASS_CONTEXT | (10 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemAF0_constraint_1, + &ASN_PER_MEMB_EPHEM_A_F0_CONSTR_12, 0, "ephemAF0"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemCrs), - (ASN_TAG_CLASS_CONTEXT | (11 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemCrs_constraint_1, - &ASN_PER_MEMB_EPHEM_CRS_CONSTR_13, 0, "ephemCrs"}, + (ASN_TAG_CLASS_CONTEXT | (11 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemCrs_constraint_1, + &ASN_PER_MEMB_EPHEM_CRS_CONSTR_13, 0, "ephemCrs"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemDeltaN), - (ASN_TAG_CLASS_CONTEXT | (12 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemDeltaN_constraint_1, - &ASN_PER_MEMB_EPHEM_DELTA_N_CONSTR_14, 0, "ephemDeltaN"}, + (ASN_TAG_CLASS_CONTEXT | (12 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemDeltaN_constraint_1, + &ASN_PER_MEMB_EPHEM_DELTA_N_CONSTR_14, 0, "ephemDeltaN"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemM0), - (ASN_TAG_CLASS_CONTEXT | (13 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemM0_constraint_1, - &ASN_PER_MEMB_EPHEM_M0_CONSTR_15, 0, "ephemM0"}, + (ASN_TAG_CLASS_CONTEXT | (13 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemM0_constraint_1, + &ASN_PER_MEMB_EPHEM_M0_CONSTR_15, 0, "ephemM0"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemCuc), - (ASN_TAG_CLASS_CONTEXT | (14 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemCuc_constraint_1, - &ASN_PER_MEMB_EPHEM_CUC_CONSTR_16, 0, "ephemCuc"}, + (ASN_TAG_CLASS_CONTEXT | (14 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemCuc_constraint_1, + &ASN_PER_MEMB_EPHEM_CUC_CONSTR_16, 0, "ephemCuc"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemE), - (ASN_TAG_CLASS_CONTEXT | (15 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_ephemE_17, memb_ephemE_constraint_1, - &ASN_PER_MEMB_EPHEM_E_CONSTR_17, 0, "ephemE"}, + (ASN_TAG_CLASS_CONTEXT | (15 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_ephemE_17, memb_ephemE_constraint_1, + &ASN_PER_MEMB_EPHEM_E_CONSTR_17, 0, "ephemE"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemCus), - (ASN_TAG_CLASS_CONTEXT | (16 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemCus_constraint_1, - &ASN_PER_MEMB_EPHEM_CUS_CONSTR_18, 0, "ephemCus"}, + (ASN_TAG_CLASS_CONTEXT | (16 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemCus_constraint_1, + &ASN_PER_MEMB_EPHEM_CUS_CONSTR_18, 0, "ephemCus"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemAPowerHalf), - (ASN_TAG_CLASS_CONTEXT | (17 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_ephemAPowerHalf_19, memb_ephemAPowerHalf_constraint_1, - &ASN_PER_MEMB_EPHEM_A_POWER_HALF_CONSTR_19, 0, "ephemAPowerHalf"}, + (ASN_TAG_CLASS_CONTEXT | (17 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_ephemAPowerHalf_19, memb_ephemAPowerHalf_constraint_1, + &ASN_PER_MEMB_EPHEM_A_POWER_HALF_CONSTR_19, 0, "ephemAPowerHalf"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemToe), - (ASN_TAG_CLASS_CONTEXT | (18 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemToe_constraint_1, - &ASN_PER_MEMB_EPHEM_TOE_CONSTR_20, 0, "ephemToe"}, + (ASN_TAG_CLASS_CONTEXT | (18 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemToe_constraint_1, + &ASN_PER_MEMB_EPHEM_TOE_CONSTR_20, 0, "ephemToe"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemFitFlag), - (ASN_TAG_CLASS_CONTEXT | (19 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemFitFlag_constraint_1, - &ASN_PER_MEMB_EPHEM_FIT_FLAG_CONSTR_21, 0, "ephemFitFlag"}, + (ASN_TAG_CLASS_CONTEXT | (19 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemFitFlag_constraint_1, + &ASN_PER_MEMB_EPHEM_FIT_FLAG_CONSTR_21, 0, "ephemFitFlag"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemAODA), - (ASN_TAG_CLASS_CONTEXT | (20 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemAODA_constraint_1, - &ASN_PER_MEMB_EPHEM_AODA_CONSTR_22, 0, "ephemAODA"}, + (ASN_TAG_CLASS_CONTEXT | (20 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemAODA_constraint_1, + &ASN_PER_MEMB_EPHEM_AODA_CONSTR_22, 0, "ephemAODA"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemCic), - (ASN_TAG_CLASS_CONTEXT | (21 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemCic_constraint_1, - &ASN_PER_MEMB_EPHEM_CIC_CONSTR_23, 0, "ephemCic"}, + (ASN_TAG_CLASS_CONTEXT | (21 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemCic_constraint_1, + &ASN_PER_MEMB_EPHEM_CIC_CONSTR_23, 0, "ephemCic"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemOmegaA0), - (ASN_TAG_CLASS_CONTEXT | (22 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemOmegaA0_constraint_1, - &ASN_PER_MEMB_EPHEM_OMEGA_A0_CONSTR_24, 0, "ephemOmegaA0"}, + (ASN_TAG_CLASS_CONTEXT | (22 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemOmegaA0_constraint_1, + &ASN_PER_MEMB_EPHEM_OMEGA_A0_CONSTR_24, 0, "ephemOmegaA0"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemCis), - (ASN_TAG_CLASS_CONTEXT | (23 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemCis_constraint_1, - &ASN_PER_MEMB_EPHEM_CIS_CONSTR_25, 0, "ephemCis"}, + (ASN_TAG_CLASS_CONTEXT | (23 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemCis_constraint_1, + &ASN_PER_MEMB_EPHEM_CIS_CONSTR_25, 0, "ephemCis"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemI0), - (ASN_TAG_CLASS_CONTEXT | (24 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemI0_constraint_1, - &ASN_PER_MEMB_EPHEM_I0_CONSTR_26, 0, "ephemI0"}, + (ASN_TAG_CLASS_CONTEXT | (24 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemI0_constraint_1, + &ASN_PER_MEMB_EPHEM_I0_CONSTR_26, 0, "ephemI0"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemCrc), - (ASN_TAG_CLASS_CONTEXT | (25 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemCrc_constraint_1, - &ASN_PER_MEMB_EPHEM_CRC_CONSTR_27, 0, "ephemCrc"}, + (ASN_TAG_CLASS_CONTEXT | (25 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemCrc_constraint_1, + &ASN_PER_MEMB_EPHEM_CRC_CONSTR_27, 0, "ephemCrc"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemW), - (ASN_TAG_CLASS_CONTEXT | (26 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemW_constraint_1, - &ASN_PER_MEMB_EPHEM_W_CONSTR_28, 0, "ephemW"}, + (ASN_TAG_CLASS_CONTEXT | (26 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemW_constraint_1, + &ASN_PER_MEMB_EPHEM_W_CONSTR_28, 0, "ephemW"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemOmegaADot), - (ASN_TAG_CLASS_CONTEXT | (27 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemOmegaADot_constraint_1, - &ASN_PER_MEMB_EPHEM_OMEGA_A_DOT_CONSTR_29, 0, "ephemOmegaADot"}, + (ASN_TAG_CLASS_CONTEXT | (27 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemOmegaADot_constraint_1, + &ASN_PER_MEMB_EPHEM_OMEGA_A_DOT_CONSTR_29, 0, "ephemOmegaADot"}, {ATF_NOFLAGS, 0, offsetof(struct UncompressedEphemeris, ephemIDot), - (ASN_TAG_CLASS_CONTEXT | (28 << 2)), - -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_ephemIDot_constraint_1, - &ASN_PER_MEMB_EPHEM_I_DOT_CONSTR_30, 0, "ephemIDot"}, + (ASN_TAG_CLASS_CONTEXT | (28 << 2)), + -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_ephemIDot_constraint_1, + &ASN_PER_MEMB_EPHEM_I_DOT_CONSTR_30, 0, "ephemIDot"}, }; static ber_tlv_tag_t asn_DEF_UncompressedEphemeris_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -1430,7 +1430,7 @@ static asn_TYPE_tag2member_t asn_MAP_UncompressedEphemeris_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (15 << 2)), 15, 0, 0}, /* ephemE at 737 */ {(ASN_TAG_CLASS_CONTEXT | (16 << 2)), 16, 0, 0}, /* ephemCus at 738 */ {(ASN_TAG_CLASS_CONTEXT | (17 << 2)), 17, 0, - 0}, /* ephemAPowerHalf at 739 */ + 0}, /* ephemAPowerHalf at 739 */ {(ASN_TAG_CLASS_CONTEXT | (18 << 2)), 18, 0, 0}, /* ephemToe at 740 */ {(ASN_TAG_CLASS_CONTEXT | (19 << 2)), 19, 0, 0}, /* ephemFitFlag at 741 */ {(ASN_TAG_CLASS_CONTEXT | (20 << 2)), 20, 0, 0}, /* ephemAODA at 742 */ @@ -1473,7 +1473,7 @@ asn_TYPE_descriptor_t asn_DEF_UncompressedEphemeris = { asn_DEF_UncompressedEphemeris_tags_1, /* Same as above */ sizeof(asn_DEF_UncompressedEphemeris_tags_1) / sizeof(asn_DEF_UncompressedEphemeris_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_UncompressedEphemeris_1, 29, /* Elements count */ &asn_SPC_UncompressedEphemeris_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-rrlp/UncompressedEphemeris.h b/src/core/libs/supl/asn-rrlp/UncompressedEphemeris.h index 43e9bf74a..f19302c45 100644 --- a/src/core/libs/supl/asn-rrlp/UncompressedEphemeris.h +++ b/src/core/libs/supl/asn-rrlp/UncompressedEphemeris.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include #include "EphemerisSubframe1Reserved.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/UseMultipleSets.c b/src/core/libs/supl/asn-rrlp/UseMultipleSets.c index 2ec5c7b96..7b5713806 100644 --- a/src/core/libs/supl/asn-rrlp/UseMultipleSets.c +++ b/src/core/libs/supl/asn-rrlp/UseMultipleSets.c @@ -7,8 +7,8 @@ #include "UseMultipleSets.h" int UseMultipleSets_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { /* Replace with underlying type checker */ td->check_constraints = asn_DEF_ENUMERATED.check_constraints; @@ -39,76 +39,76 @@ static void UseMultipleSets_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void UseMultipleSets_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { UseMultipleSets_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int UseMultipleSets_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, + void *app_key) { UseMultipleSets_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t UseMultipleSets_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { UseMultipleSets_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t UseMultipleSets_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { UseMultipleSets_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t UseMultipleSets_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { UseMultipleSets_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t UseMultipleSets_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { UseMultipleSets_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t UseMultipleSets_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { UseMultipleSets_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t UseMultipleSets_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { UseMultipleSets_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-rrlp/VelocityEstimate.c b/src/core/libs/supl/asn-rrlp/VelocityEstimate.c index dbe8617c6..f0d0a68af 100644 --- a/src/core/libs/supl/asn-rrlp/VelocityEstimate.c +++ b/src/core/libs/supl/asn-rrlp/VelocityEstimate.c @@ -7,8 +7,8 @@ #include "VelocityEstimate.h" int VelocityEstimate_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { /* Replace with underlying type checker */ td->check_constraints = asn_DEF_INTEGER.check_constraints; @@ -38,76 +38,76 @@ static void VelocityEstimate_1_inherit_TYPE_descriptor( } void VelocityEstimate_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { VelocityEstimate_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int VelocityEstimate_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, + void *app_key) { VelocityEstimate_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t VelocityEstimate_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { VelocityEstimate_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t VelocityEstimate_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { VelocityEstimate_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t VelocityEstimate_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { VelocityEstimate_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t VelocityEstimate_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { VelocityEstimate_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t VelocityEstimate_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { VelocityEstimate_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t VelocityEstimate_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { VelocityEstimate_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); @@ -134,7 +134,7 @@ asn_TYPE_descriptor_t asn_DEF_VelocityEstimate = { asn_DEF_VelocityEstimate_tags_1, /* Same as above */ sizeof(asn_DEF_VelocityEstimate_tags_1) / sizeof(asn_DEF_VelocityEstimate_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ 0, 0, /* No members */ 0 /* No specifics */ diff --git a/src/core/libs/supl/asn-rrlp/asn_SEQUENCE_OF.c b/src/core/libs/supl/asn-rrlp/asn_SEQUENCE_OF.c index 924cb150e..67981e72f 100644 --- a/src/core/libs/supl/asn-rrlp/asn_SEQUENCE_OF.c +++ b/src/core/libs/supl/asn-rrlp/asn_SEQUENCE_OF.c @@ -2,8 +2,8 @@ * Copyright (c) 2003, 2004 Lev Walkin . All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ -#include #include +#include typedef A_SEQUENCE_OF(void) asn_sequence; diff --git a/src/core/libs/supl/asn-rrlp/asn_SET_OF.c b/src/core/libs/supl/asn-rrlp/asn_SET_OF.c index 2239dbe58..317ebea09 100644 --- a/src/core/libs/supl/asn-rrlp/asn_SET_OF.c +++ b/src/core/libs/supl/asn-rrlp/asn_SET_OF.c @@ -2,8 +2,8 @@ * Copyright (c) 2003, 2004 Lev Walkin . All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ -#include #include +#include #include /* diff --git a/src/core/libs/supl/asn-rrlp/asn_application.h b/src/core/libs/supl/asn-rrlp/asn_application.h index ec8567737..baf070e4a 100644 --- a/src/core/libs/supl/asn-rrlp/asn_application.h +++ b/src/core/libs/supl/asn-rrlp/asn_application.h @@ -8,8 +8,10 @@ #ifndef _ASN_APPLICATION_H_ #define _ASN_APPLICATION_H_ +// clang-format off #include "asn_system.h" /* for platform-dependent types */ #include "asn_codecs.h" /* for ASN.1 codecs specifics */ +// clang-format on #ifdef __cplusplus extern "C" @@ -24,7 +26,7 @@ extern "C" * Non-negative return values indicate success, and ignored. */ typedef int(asn_app_consume_bytes_f)(const void *buffer, size_t size, - void *application_specific_key); + void *application_specific_key); /* * A callback of this type is called whenever constraint validation fails diff --git a/src/core/libs/supl/asn-rrlp/asn_codecs_prim.c b/src/core/libs/supl/asn-rrlp/asn_codecs_prim.c index 692601c17..75b51ad38 100644 --- a/src/core/libs/supl/asn-rrlp/asn_codecs_prim.c +++ b/src/core/libs/supl/asn-rrlp/asn_codecs_prim.c @@ -2,17 +2,17 @@ * Copyright (c) 2003, 2004 Lev Walkin . All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ -#include #include +#include #include /* * Decode an always-primitive type. */ asn_dec_rval_t ber_decode_primitive(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **sptr, - const void *buf_ptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, void **sptr, + const void *buf_ptr, size_t size, + int tag_mode) { ASN__PRIMITIVE_TYPE_t *st = (ASN__PRIMITIVE_TYPE_t *)*sptr; asn_dec_rval_t rval; @@ -34,7 +34,7 @@ asn_dec_rval_t ber_decode_primitive(asn_codec_ctx_t *opt_codec_ctx, * Check tags and extract value length. */ rval = ber_check_tags(opt_codec_ctx, td, 0, buf_ptr, size, tag_mode, 0, - &length, 0); + &length, 0); if (rval.code != RC_OK) return rval; ASN_DEBUG("%s length is %d bytes", td->name, (int)length); @@ -73,7 +73,7 @@ asn_dec_rval_t ber_decode_primitive(asn_codec_ctx_t *opt_codec_ctx, rval.consumed += length; ASN_DEBUG("Took %ld/%ld bytes to encode %s", (long)rval.consumed, - (long)length, td->name); + (long)length, td->name); return rval; } @@ -82,14 +82,14 @@ asn_dec_rval_t ber_decode_primitive(asn_codec_ctx_t *opt_codec_ctx, * Encode an always-primitive type using DER. */ asn_enc_rval_t der_encode_primitive(asn_TYPE_descriptor_t *td, void *sptr, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { asn_enc_rval_t erval; ASN__PRIMITIVE_TYPE_t *st = (ASN__PRIMITIVE_TYPE_t *)sptr; ASN_DEBUG("%s %s as a primitive type (tm=%d)", - cb ? "Encoding" : "Estimating", td->name, tag_mode); + cb ? "Encoding" : "Estimating", td->name, tag_mode); erval.encoded = der_write_tags(td, st->size, tag_mode, 0, tag, cb, app_key); ASN_DEBUG("%s wrote tags %d", td->name, (int)erval.encoded); @@ -120,7 +120,7 @@ asn_enc_rval_t der_encode_primitive(asn_TYPE_descriptor_t *td, void *sptr, } void ASN__PRIMITIVE_TYPE_free(asn_TYPE_descriptor_t *td, void *sptr, - int contents_only) + int contents_only) { ASN__PRIMITIVE_TYPE_t *st = (ASN__PRIMITIVE_TYPE_t *)sptr; @@ -146,7 +146,7 @@ struct xdp_arg_s }; static int xer_decode__unexpected_tag(void *key, const void *chunk_buf, - size_t chunk_size) + size_t chunk_size) { struct xdp_arg_s *arg = (struct xdp_arg_s *)key; enum xer_pbd_rval bret; @@ -162,26 +162,26 @@ static int xer_decode__unexpected_tag(void *key, const void *chunk_buf, } bret = arg->prim_body_decoder(arg->type_descriptor, arg->struct_key, - chunk_buf, chunk_size); + chunk_buf, chunk_size); switch (bret) { - case XPBD_SYSTEM_FAILURE: - case XPBD_DECODER_LIMIT: - case XPBD_BROKEN_ENCODING: - break; - case XPBD_BODY_CONSUMED: - /* Tag decoded successfully */ - arg->decoded_something = 1; - /* Fall through */ - case XPBD_NOT_BODY_IGNORE: /* Safe to proceed further */ - return 0; + case XPBD_SYSTEM_FAILURE: + case XPBD_DECODER_LIMIT: + case XPBD_BROKEN_ENCODING: + break; + case XPBD_BODY_CONSUMED: + /* Tag decoded successfully */ + arg->decoded_something = 1; + /* Fall through */ + case XPBD_NOT_BODY_IGNORE: /* Safe to proceed further */ + return 0; } return -1; } static ssize_t xer_decode__body(void *key, const void *chunk_buf, - size_t chunk_size, int have_more) + size_t chunk_size, int have_more) { struct xdp_arg_s *arg = (struct xdp_arg_s *)key; enum xer_pbd_rval bret; @@ -210,19 +210,19 @@ static ssize_t xer_decode__body(void *key, const void *chunk_buf, } bret = arg->prim_body_decoder(arg->type_descriptor, arg->struct_key, - chunk_buf, chunk_size); + chunk_buf, chunk_size); switch (bret) { - case XPBD_SYSTEM_FAILURE: - case XPBD_DECODER_LIMIT: - case XPBD_BROKEN_ENCODING: - break; - case XPBD_BODY_CONSUMED: - /* Tag decoded successfully */ - arg->decoded_something = 1; - /* Fall through */ - case XPBD_NOT_BODY_IGNORE: /* Safe to proceed further */ - return chunk_size; + case XPBD_SYSTEM_FAILURE: + case XPBD_DECODER_LIMIT: + case XPBD_BROKEN_ENCODING: + break; + case XPBD_BODY_CONSUMED: + /* Tag decoded successfully */ + arg->decoded_something = 1; + /* Fall through */ + case XPBD_NOT_BODY_IGNORE: /* Safe to proceed further */ + return chunk_size; } return -1; @@ -255,46 +255,46 @@ asn_dec_rval_t xer_decode_primitive( s_arg.want_more = 0; rc = xer_decode_general(opt_codec_ctx, &s_ctx, &s_arg, xml_tag, buf_ptr, - size, xer_decode__unexpected_tag, xer_decode__body); + size, xer_decode__unexpected_tag, xer_decode__body); switch (rc.code) { - case RC_OK: - if (!s_arg.decoded_something) - { - char ch; - ASN_DEBUG( - "Primitive body is not recognized, " - "supplying empty one"); - /* + case RC_OK: + if (!s_arg.decoded_something) + { + char ch; + ASN_DEBUG( + "Primitive body is not recognized, " + "supplying empty one"); + /* * Decoding opportunity has come and gone. * Where's the result? * Try to feed with empty body, see if it eats it. */ - if (prim_body_decoder(s_arg.type_descriptor, - s_arg.struct_key, &ch, - 0) != XPBD_BODY_CONSUMED) - { - /* + if (prim_body_decoder(s_arg.type_descriptor, + s_arg.struct_key, &ch, + 0) != XPBD_BODY_CONSUMED) + { + /* * This decoder does not like empty stuff. */ - _ASN_DECODE_FAILED; - } - } - break; - case RC_WMORE: - /* + _ASN_DECODE_FAILED; + } + } + break; + case RC_WMORE: + /* * Redo the whole thing later. * We don't have a context to save intermediate parsing state. */ - rc.consumed = 0; - break; - case RC_FAIL: - rc.consumed = 0; - if (s_arg.want_more) - rc.code = RC_WMORE; - else - _ASN_DECODE_FAILED; - break; + rc.consumed = 0; + break; + case RC_FAIL: + rc.consumed = 0; + if (s_arg.want_more) + rc.code = RC_WMORE; + else + _ASN_DECODE_FAILED; + break; } return rc; } diff --git a/src/core/libs/supl/asn-rrlp/asn_codecs_prim.h b/src/core/libs/supl/asn-rrlp/asn_codecs_prim.h index b3108aed5..b8a4a0129 100644 --- a/src/core/libs/supl/asn-rrlp/asn_codecs_prim.h +++ b/src/core/libs/supl/asn-rrlp/asn_codecs_prim.h @@ -14,8 +14,8 @@ extern "C" typedef struct ASN__PRIMITIVE_TYPE_s { - uint8_t *buf; /* Buffer with consecutive primitive encoding bytes */ - int size; /* Size of the buffer */ + uint8_t *buf; /* Buffer with consecutive primitive encoding bytes */ + int size; /* Size of the buffer */ } ASN__PRIMITIVE_TYPE_t; /* Do not use this type directly! */ asn_struct_free_f ASN__PRIMITIVE_TYPE_free; diff --git a/src/core/libs/supl/asn-rrlp/asn_internal.h b/src/core/libs/supl/asn-rrlp/asn_internal.h index 339dc86e4..2e0a994b4 100644 --- a/src/core/libs/supl/asn-rrlp/asn_internal.h +++ b/src/core/libs/supl/asn-rrlp/asn_internal.h @@ -55,7 +55,10 @@ extern "C" #define ASN_DEBUG ASN_DEBUG_f #endif /* __GNUC__ */ #else /* EMIT_ASN_DEBUG != 1 */ - static inline void ASN_DEBUG(const char *fmt, ...) { (void)fmt; } + static inline void ASN_DEBUG(const char *fmt, ...) + { + (void)fmt; + } #endif /* EMIT_ASN_DEBUG */ #endif /* ASN_DEBUG */ @@ -115,7 +118,7 @@ extern "C" if (usedstack < -(ptrdiff_t)ctx->max_stack_size) { ASN_DEBUG("Stack limit %ld reached", - (long)ctx->max_stack_size); + (long)ctx->max_stack_size); return -1; } } diff --git a/src/core/libs/supl/asn-rrlp/asn_system.h b/src/core/libs/supl/asn-rrlp/asn_system.h index 5eacc2ecb..1fa6461f9 100644 --- a/src/core/libs/supl/asn-rrlp/asn_system.h +++ b/src/core/libs/supl/asn-rrlp/asn_system.h @@ -13,13 +13,13 @@ #include "config.h" #endif +#include /* For LONG_MAX */ +#include /* For va_start */ +#include /* for offsetof and ptrdiff_t */ #include /* For snprintf(3) */ #include /* For *alloc(3) */ #include /* For memcpy(3) */ #include /* For size_t */ -#include /* For LONG_MAX */ -#include /* For va_start */ -#include /* for offsetof and ptrdiff_t */ #ifdef WIN32 @@ -30,7 +30,7 @@ /* To avoid linking with ws2_32.lib, here's the definition of ntohl() */ #define sys_ntohl(l) \ ((((l) << 24) & 0xff000000) | (((l) << 16) & 0xff0000) | \ - (((l) << 8) & 0xff00) | ((l)&0xff)) + (((l) << 8) & 0xff00) | ((l)&0xff)) #ifdef _MSC_VER /* MSVS.Net */ #ifndef __cplusplus @@ -46,8 +46,8 @@ typedef unsigned short uint16_t; typedef unsigned int uint32_t; #endif /* ASSUMESTDTYPES */ #define WIN32_LEAN_AND_MEAN -#include #include +#include #define isnan _isnan #define finite _finite #define copysign _copysign diff --git a/src/core/libs/supl/asn-rrlp/ber_decoder.c b/src/core/libs/supl/asn-rrlp/ber_decoder.c index 36fc4b9d2..c2dbabbfe 100644 --- a/src/core/libs/supl/asn-rrlp/ber_decoder.c +++ b/src/core/libs/supl/asn-rrlp/ber_decoder.c @@ -33,8 +33,8 @@ * The BER decoder of any type. */ asn_dec_rval_t ber_decode(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *type_descriptor, - void **struct_ptr, const void *ptr, size_t size) + asn_TYPE_descriptor_t *type_descriptor, + void **struct_ptr, const void *ptr, size_t size) { asn_codec_ctx_t s_codec_ctx; @@ -73,10 +73,10 @@ asn_dec_rval_t ber_decode(asn_codec_ctx_t *opt_codec_ctx, * Check the set of >> tags matches the definition. */ asn_dec_rval_t ber_check_tags(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_struct_ctx_t *opt_ctx, const void *ptr, - size_t size, int tag_mode, int last_tag_form, - ber_tlv_len_t *last_length, int *opt_tlv_form) + asn_TYPE_descriptor_t *td, + asn_struct_ctx_t *opt_ctx, const void *ptr, + size_t size, int tag_mode, int last_tag_form, + ber_tlv_len_t *last_length, int *opt_tlv_form) { ssize_t consumed_myself = 0; ssize_t tag_len; @@ -85,7 +85,7 @@ asn_dec_rval_t ber_check_tags(asn_codec_ctx_t *opt_codec_ctx, ber_tlv_len_t tlv_len; ber_tlv_len_t limit_len = -1; int expect_00_terminators = 0; - int tlv_constr = -1; /* If CHOICE, opt_tlv_form is not given */ + int tlv_constr = -1; /* If CHOICE, opt_tlv_form is not given */ int step = opt_ctx ? opt_ctx->step : 0; /* Where we left previously */ int tagno; @@ -119,7 +119,7 @@ asn_dec_rval_t ber_check_tags(asn_codec_ctx_t *opt_codec_ctx, tagno = step /* Continuing where left previously */ + (tag_mode == 1 ? -1 : 0); ASN_DEBUG("ber_check_tags(%s, size=%ld, tm=%d, step=%d, tagno=%d)", - td->name, (long)size, tag_mode, step, tagno); + td->name, (long)size, tag_mode, step, tagno); /* assert(td->tags_count >= 1) May not be the case for CHOICE or ANY */ if (tag_mode == 0 && tagno == td->tags_count) @@ -132,20 +132,20 @@ asn_dec_rval_t ber_check_tags(asn_codec_ctx_t *opt_codec_ctx, tag_len = ber_fetch_tag(ptr, size, &tlv_tag); switch (tag_len) { - case -1: - RETURN(RC_FAIL); - case 0: - RETURN(RC_WMORE); + case -1: + RETURN(RC_FAIL); + case 0: + RETURN(RC_WMORE); } tlv_constr = BER_TLV_CONSTRUCTED(ptr); len_len = ber_fetch_length(tlv_constr, (const char *)ptr + tag_len, - size - tag_len, &tlv_len); + size - tag_len, &tlv_len); switch (len_len) { - case -1: - RETURN(RC_FAIL); - case 0: - RETURN(RC_WMORE); + case -1: + RETURN(RC_FAIL); + case 0: + RETURN(RC_WMORE); } ASN_DEBUG("Advancing %ld in ANY case", (tag_len + len_len)); ADVANCE(tag_len + len_len); @@ -167,10 +167,10 @@ asn_dec_rval_t ber_check_tags(asn_codec_ctx_t *opt_codec_ctx, ber_tlv_tag_string(tlv_tag)); switch (tag_len) { - case -1: - RETURN(RC_FAIL); - case 0: - RETURN(RC_WMORE); + case -1: + RETURN(RC_FAIL); + case 0: + RETURN(RC_WMORE); } tlv_constr = BER_TLV_CONSTRUCTED(ptr); @@ -224,7 +224,7 @@ asn_dec_rval_t ber_check_tags(asn_codec_ctx_t *opt_codec_ctx, if (last_tag_form != tlv_constr && last_tag_form != -1) { ASN_DEBUG("last_tag_form %d != %d", last_tag_form, - tlv_constr); + tlv_constr); RETURN(RC_FAIL); } } @@ -233,14 +233,14 @@ asn_dec_rval_t ber_check_tags(asn_codec_ctx_t *opt_codec_ctx, * Fetch and process L from TLV. */ len_len = ber_fetch_length(tlv_constr, (const char *)ptr + tag_len, - size - tag_len, &tlv_len); + size - tag_len, &tlv_len); ASN_DEBUG("Fetchinig len = %ld", (long)len_len); switch (len_len) { - case -1: - RETURN(RC_FAIL); - case 0: - RETURN(RC_WMORE); + case -1: + RETURN(RC_FAIL); + case 0: + RETURN(RC_WMORE); } /* @@ -300,7 +300,7 @@ asn_dec_rval_t ber_check_tags(asn_codec_ctx_t *opt_codec_ctx, * with the outer TLV's length value. */ ASN_DEBUG("Outer TLV is %ld and inner is %ld", - (long)limit_len, (long)tlv_len); + (long)limit_len, (long)tlv_len); RETURN(RC_FAIL); } diff --git a/src/core/libs/supl/asn-rrlp/ber_decoder.h b/src/core/libs/supl/asn-rrlp/ber_decoder.h index 8a7f77efa..18224c442 100644 --- a/src/core/libs/supl/asn-rrlp/ber_decoder.h +++ b/src/core/libs/supl/asn-rrlp/ber_decoder.h @@ -53,8 +53,8 @@ extern "C" struct asn_TYPE_descriptor_s *type_descriptor, asn_struct_ctx_t *opt_ctx, /* saved decoding context */ const void *ptr, size_t size, - int tag_mode, /* {-1,0,1}: IMPLICIT, no, EXPLICIT */ - int last_tag_form, /* {-1,0:1}: any, primitive, constr */ + int tag_mode, /* {-1,0,1}: IMPLICIT, no, EXPLICIT */ + int last_tag_form, /* {-1,0:1}: any, primitive, constr */ ber_tlv_len_t *last_length, int *opt_tlv_form /* optional tag form */ ); diff --git a/src/core/libs/supl/asn-rrlp/ber_tlv_length.c b/src/core/libs/supl/asn-rrlp/ber_tlv_length.c index 9d6e2998d..4efe95b95 100644 --- a/src/core/libs/supl/asn-rrlp/ber_tlv_length.c +++ b/src/core/libs/supl/asn-rrlp/ber_tlv_length.c @@ -7,7 +7,7 @@ #include ssize_t ber_fetch_length(int _is_constructed, const void *bufptr, size_t size, - ber_tlv_len_t *len_r) + ber_tlv_len_t *len_r) { const uint8_t *buf = (const uint8_t *)bufptr; unsigned oct; @@ -80,7 +80,7 @@ ssize_t ber_fetch_length(int _is_constructed, const void *bufptr, size_t size, } ssize_t ber_skip_length(asn_codec_ctx_t *opt_codec_ctx, int _is_constructed, - const void *ptr, size_t size) + const void *ptr, size_t size) { ber_tlv_len_t vlen; /* Length of V in TLV */ ssize_t tl; /* Length of L in TLV */ @@ -121,7 +121,7 @@ ssize_t ber_skip_length(asn_codec_ctx_t *opt_codec_ctx, int _is_constructed, if (tl <= 0) return tl; ll = ber_skip_length(opt_codec_ctx, BER_TLV_CONSTRUCTED(ptr), - ((const char *)ptr) + tl, size - tl); + ((const char *)ptr) + tl, size - tl); if (ll <= 0) return ll; skip += tl + ll; diff --git a/src/core/libs/supl/asn-rrlp/ber_tlv_length.h b/src/core/libs/supl/asn-rrlp/ber_tlv_length.h index 9daae27af..211855c29 100644 --- a/src/core/libs/supl/asn-rrlp/ber_tlv_length.h +++ b/src/core/libs/supl/asn-rrlp/ber_tlv_length.h @@ -23,7 +23,7 @@ extern "C" * that the value is of indefinite length. */ ssize_t ber_fetch_length(int _is_constructed, const void *bufptr, - size_t size, ber_tlv_len_t *len_r); + size_t size, ber_tlv_len_t *len_r); /* * This function expects bufptr to be positioned over L in TLV. @@ -43,7 +43,7 @@ extern "C" * against the supplied buffer's size. */ size_t der_tlv_length_serialize(ber_tlv_len_t len, void *bufptr, - size_t size); + size_t size); #ifdef __cplusplus } diff --git a/src/core/libs/supl/asn-rrlp/ber_tlv_tag.c b/src/core/libs/supl/asn-rrlp/ber_tlv_tag.c index 2de303992..0bef65296 100644 --- a/src/core/libs/supl/asn-rrlp/ber_tlv_tag.c +++ b/src/core/libs/supl/asn-rrlp/ber_tlv_tag.c @@ -83,18 +83,18 @@ ssize_t ber_tlv_tag_snprint(ber_tlv_tag_t tag, char *buf, size_t size) switch (tag & 0x3) { - case ASN_TAG_CLASS_UNIVERSAL: - type = "UNIVERSAL "; - break; - case ASN_TAG_CLASS_APPLICATION: - type = "APPLICATION "; - break; - case ASN_TAG_CLASS_CONTEXT: - type = ""; - break; - case ASN_TAG_CLASS_PRIVATE: - type = "PRIVATE "; - break; + case ASN_TAG_CLASS_UNIVERSAL: + type = "UNIVERSAL "; + break; + case ASN_TAG_CLASS_APPLICATION: + type = "APPLICATION "; + break; + case ASN_TAG_CLASS_CONTEXT: + type = ""; + break; + case ASN_TAG_CLASS_PRIVATE: + type = "PRIVATE "; + break; } ret = snprintf(buf, size, "[%s%u]", type, ((unsigned)tag) >> 2); diff --git a/src/core/libs/supl/asn-rrlp/ber_tlv_tag.h b/src/core/libs/supl/asn-rrlp/ber_tlv_tag.h index 0693688c6..011f0af32 100644 --- a/src/core/libs/supl/asn-rrlp/ber_tlv_tag.h +++ b/src/core/libs/supl/asn-rrlp/ber_tlv_tag.h @@ -46,7 +46,7 @@ extern "C" * >0: Number of bytes used from bufptr. tag_r will contain the tag. */ ssize_t ber_fetch_tag(const void *bufptr, size_t size, - ber_tlv_tag_t *tag_r); + ber_tlv_tag_t *tag_r); /* * This function serializes the tag (T from TLV) in BER format. diff --git a/src/core/libs/supl/asn-rrlp/constr_CHOICE.c b/src/core/libs/supl/asn-rrlp/constr_CHOICE.c index 62682ab72..7c0917700 100644 --- a/src/core/libs/supl/asn-rrlp/constr_CHOICE.c +++ b/src/core/libs/supl/asn-rrlp/constr_CHOICE.c @@ -72,7 +72,7 @@ * See the definitions. */ static int _fetch_present_idx(const void *struct_ptr, int pres_offset, - int size); + int size); static void _set_present_idx(void *struct_ptr, int offset, int size, int pres); /* @@ -112,8 +112,8 @@ static int _search4tag(const void *ap, const void *bp) * The decoder of the CHOICE type. */ asn_dec_rval_t CHOICE_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **struct_ptr, - const void *ptr, size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, void **struct_ptr, + const void *ptr, size_t size, int tag_mode) { /* * Bring closer parts of structure description. @@ -157,265 +157,265 @@ asn_dec_rval_t CHOICE_decode_ber(asn_codec_ctx_t *opt_codec_ctx, */ switch (ctx->phase) { - case 0: - /* + case 0: + /* * PHASE 0. * Check that the set of tags associated with given structure * perfectly fits our expectations. */ - if (tag_mode || td->tags_count) - { - rval = ber_check_tags(opt_codec_ctx, td, ctx, ptr, size, - tag_mode, -1, &ctx->left, 0); - if (rval.code != RC_OK) - { - ASN_DEBUG("%s tagging check failed: %d", - td->name, rval.code); - return rval; - } + if (tag_mode || td->tags_count) + { + rval = ber_check_tags(opt_codec_ctx, td, ctx, ptr, size, + tag_mode, -1, &ctx->left, 0); + if (rval.code != RC_OK) + { + ASN_DEBUG("%s tagging check failed: %d", + td->name, rval.code); + return rval; + } - if (ctx->left >= 0) - { - /* ?Subtracted below! */ - ctx->left += rval.consumed; - } - ADVANCE(rval.consumed); - } - else - { - ctx->left = -1; - } + if (ctx->left >= 0) + { + /* ?Subtracted below! */ + ctx->left += rval.consumed; + } + ADVANCE(rval.consumed); + } + else + { + ctx->left = -1; + } - NEXT_PHASE(ctx); + NEXT_PHASE(ctx); - ASN_DEBUG("Structure consumes %ld bytes, buffer %ld", - (long)ctx->left, (long)size); + ASN_DEBUG("Structure consumes %ld bytes, buffer %ld", + (long)ctx->left, (long)size); - /* Fall through */ - case 1: - /* + /* Fall through */ + case 1: + /* * Fetch the T from TLV. */ - tag_len = ber_fetch_tag(ptr, LEFT, &tlv_tag); - ASN_DEBUG("In %s CHOICE tag length %d", td->name, (int)tag_len); - switch (tag_len) - { - case 0: - if (!SIZE_VIOLATION) RETURN(RC_WMORE); - /* Fall through */ - case -1: - RETURN(RC_FAIL); - } + tag_len = ber_fetch_tag(ptr, LEFT, &tlv_tag); + ASN_DEBUG("In %s CHOICE tag length %d", td->name, (int)tag_len); + switch (tag_len) + { + case 0: + if (!SIZE_VIOLATION) RETURN(RC_WMORE); + /* Fall through */ + case -1: + RETURN(RC_FAIL); + } - do - { - asn_TYPE_tag2member_t *t2m; - asn_TYPE_tag2member_t key; + do + { + asn_TYPE_tag2member_t *t2m; + asn_TYPE_tag2member_t key; - key.el_tag = tlv_tag; - t2m = (asn_TYPE_tag2member_t *)bsearch( - &key, specs->tag2el, specs->tag2el_count, - sizeof(specs->tag2el[0]), _search4tag); - if (t2m) - { - /* + key.el_tag = tlv_tag; + t2m = (asn_TYPE_tag2member_t *)bsearch( + &key, specs->tag2el, specs->tag2el_count, + sizeof(specs->tag2el[0]), _search4tag); + if (t2m) + { + /* * Found the element corresponding to the tag. */ - NEXT_PHASE(ctx); - ctx->step = t2m->el_no; - break; - } - else if (specs->ext_start == -1) - { - ASN_DEBUG( - "Unexpected tag %s " - "in non-extensible CHOICE %s", - ber_tlv_tag_string(tlv_tag), td->name); - RETURN(RC_FAIL); - } - else - { - /* Skip this tag */ - ssize_t skip; + NEXT_PHASE(ctx); + ctx->step = t2m->el_no; + break; + } + else if (specs->ext_start == -1) + { + ASN_DEBUG( + "Unexpected tag %s " + "in non-extensible CHOICE %s", + ber_tlv_tag_string(tlv_tag), td->name); + RETURN(RC_FAIL); + } + else + { + /* Skip this tag */ + ssize_t skip; - ASN_DEBUG("Skipping unknown tag %s", - ber_tlv_tag_string(tlv_tag)); + ASN_DEBUG("Skipping unknown tag %s", + ber_tlv_tag_string(tlv_tag)); - skip = ber_skip_length( - opt_codec_ctx, BER_TLV_CONSTRUCTED(ptr), - (const char *)ptr + tag_len, - LEFT - tag_len); + skip = ber_skip_length( + opt_codec_ctx, BER_TLV_CONSTRUCTED(ptr), + (const char *)ptr + tag_len, + LEFT - tag_len); - switch (skip) - { - case 0: - if (!SIZE_VIOLATION) - RETURN(RC_WMORE); - /* Fall through */ - case -1: - RETURN(RC_FAIL); - } + switch (skip) + { + case 0: + if (!SIZE_VIOLATION) + RETURN(RC_WMORE); + /* Fall through */ + case -1: + RETURN(RC_FAIL); + } - ADVANCE(skip + tag_len); - RETURN(RC_OK); - } - } - while (0); + ADVANCE(skip + tag_len); + RETURN(RC_OK); + } + } + while (0); - case 2: - /* + case 2: + /* * PHASE 2. * Read in the element. */ - do - { - asn_TYPE_member_t *elm; /* CHOICE's element */ - void *memb_ptr; /* Pointer to the member */ - void **memb_ptr2; /* Pointer to that pointer */ + do + { + asn_TYPE_member_t *elm; /* CHOICE's element */ + void *memb_ptr; /* Pointer to the member */ + void **memb_ptr2; /* Pointer to that pointer */ - elm = &elements[ctx->step]; + elm = &elements[ctx->step]; - /* + /* * Compute the position of the member inside a * structure, and also a type of containment (it may be * contained as pointer or using inline inclusion). */ - if (elm->flags & ATF_POINTER) - { - /* Member is a pointer to another structure */ - memb_ptr2 = - (void **)((char *)st + elm->memb_offset); - } - else - { - /* + if (elm->flags & ATF_POINTER) + { + /* Member is a pointer to another structure */ + memb_ptr2 = + (void **)((char *)st + elm->memb_offset); + } + else + { + /* * A pointer to a pointer * holding the start of the structure */ - memb_ptr = (char *)st + elm->memb_offset; - memb_ptr2 = &memb_ptr; - } - /* Set presence to be able to free it properly at any + memb_ptr = (char *)st + elm->memb_offset; + memb_ptr2 = &memb_ptr; + } + /* Set presence to be able to free it properly at any * time */ - _set_present_idx(st, specs->pres_offset, - specs->pres_size, ctx->step + 1); - /* + _set_present_idx(st, specs->pres_offset, + specs->pres_size, ctx->step + 1); + /* * Invoke the member fetch routine according to member's * type */ - rval = elm->type->ber_decoder(opt_codec_ctx, elm->type, - memb_ptr2, ptr, LEFT, - elm->tag_mode); - switch (rval.code) - { - case RC_OK: - break; - case RC_WMORE: /* More data expected */ - if (!SIZE_VIOLATION) - { - ADVANCE(rval.consumed); - RETURN(RC_WMORE); - } - RETURN(RC_FAIL); - case RC_FAIL: /* Fatal error */ - RETURN(rval.code); - } /* switch(rval) */ + rval = elm->type->ber_decoder(opt_codec_ctx, elm->type, + memb_ptr2, ptr, LEFT, + elm->tag_mode); + switch (rval.code) + { + case RC_OK: + break; + case RC_WMORE: /* More data expected */ + if (!SIZE_VIOLATION) + { + ADVANCE(rval.consumed); + RETURN(RC_WMORE); + } + RETURN(RC_FAIL); + case RC_FAIL: /* Fatal error */ + RETURN(rval.code); + } /* switch(rval) */ - ADVANCE(rval.consumed); - } - while (0); + ADVANCE(rval.consumed); + } + while (0); - NEXT_PHASE(ctx); + NEXT_PHASE(ctx); - /* Fall through */ - case 3: - ASN_DEBUG("CHOICE %s Leftover: %ld, size = %ld, tm=%d, tc=%d", - td->name, (long)ctx->left, (long)size, tag_mode, - td->tags_count); + /* Fall through */ + case 3: + ASN_DEBUG("CHOICE %s Leftover: %ld, size = %ld, tm=%d, tc=%d", + td->name, (long)ctx->left, (long)size, tag_mode, + td->tags_count); - if (ctx->left > 0) - { - /* + if (ctx->left > 0) + { + /* * The type must be fully decoded * by the CHOICE member-specific decoder. */ - RETURN(RC_FAIL); - } + RETURN(RC_FAIL); + } - if (ctx->left == -1 && !(tag_mode || td->tags_count)) - { - /* + if (ctx->left == -1 && !(tag_mode || td->tags_count)) + { + /* * This is an untagged CHOICE. * It doesn't contain nothing * except for the member itself, including all its tags. * The decoding is completed. */ - NEXT_PHASE(ctx); - break; - } + NEXT_PHASE(ctx); + break; + } - /* + /* * Read in the "end of data chunks"'s. */ - while (ctx->left < 0) - { - ssize_t tl; + while (ctx->left < 0) + { + ssize_t tl; - tl = ber_fetch_tag(ptr, LEFT, &tlv_tag); - switch (tl) - { - case 0: - if (!SIZE_VIOLATION) RETURN(RC_WMORE); - /* Fall through */ - case -1: - RETURN(RC_FAIL); - } + tl = ber_fetch_tag(ptr, LEFT, &tlv_tag); + switch (tl) + { + case 0: + if (!SIZE_VIOLATION) RETURN(RC_WMORE); + /* Fall through */ + case -1: + RETURN(RC_FAIL); + } - /* + /* * Expected <0><0>... */ - if (((const uint8_t *)ptr)[0] == 0) - { - if (LEFT < 2) - { - if (SIZE_VIOLATION) - RETURN(RC_FAIL); - else - RETURN(RC_WMORE); - } - else if (((const uint8_t *)ptr)[1] == 0) - { - /* + if (((const uint8_t *)ptr)[0] == 0) + { + if (LEFT < 2) + { + if (SIZE_VIOLATION) + RETURN(RC_FAIL); + else + RETURN(RC_WMORE); + } + else if (((const uint8_t *)ptr)[1] == 0) + { + /* * Correctly finished with <0><0>. */ - ADVANCE(2); - ctx->left++; - continue; - } - } - else - { - ASN_DEBUG("Unexpected continuation in %s", - td->name); - RETURN(RC_FAIL); - } + ADVANCE(2); + ctx->left++; + continue; + } + } + else + { + ASN_DEBUG("Unexpected continuation in %s", + td->name); + RETURN(RC_FAIL); + } - /* UNREACHABLE */ - } + /* UNREACHABLE */ + } - NEXT_PHASE(ctx); - case 4: - /* No meaningful work here */ - break; + NEXT_PHASE(ctx); + case 4: + /* No meaningful work here */ + break; } RETURN(RC_OK); } asn_enc_rval_t CHOICE_encode_der(asn_TYPE_descriptor_t *td, void *sptr, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { asn_CHOICE_specifics_t *specs = (asn_CHOICE_specifics_t *)td->specifics; asn_TYPE_member_t *elm; /* CHOICE element */ @@ -482,12 +482,12 @@ asn_enc_rval_t CHOICE_encode_der(asn_TYPE_descriptor_t *td, void *sptr, /* Encode member with its tag */ erval = elm->type->der_encoder(elm->type, memb_ptr, elm->tag_mode, - elm->tag, 0, 0); + elm->tag, 0, 0); if (erval.encoded == -1) return erval; /* Encode CHOICE with parent or my own tag */ ret = der_write_tags(td, erval.encoded, tag_mode, 1, tag, cb, - app_key); + app_key); if (ret == -1) _ASN_ENCODE_FAILED; computed_size += ret; } @@ -496,11 +496,11 @@ asn_enc_rval_t CHOICE_encode_der(asn_TYPE_descriptor_t *td, void *sptr, * Encode the single underlying member. */ erval = elm->type->der_encoder(elm->type, memb_ptr, elm->tag_mode, elm->tag, - cb, app_key); + cb, app_key); if (erval.encoded == -1) return erval; ASN_DEBUG("Encoded CHOICE member in %ld bytes (+%ld)", (long)erval.encoded, - (long)computed_size); + (long)computed_size); erval.encoded += computed_size; @@ -508,7 +508,7 @@ asn_enc_rval_t CHOICE_encode_der(asn_TYPE_descriptor_t *td, void *sptr, } ber_tlv_tag_t CHOICE_outmost_tag(asn_TYPE_descriptor_t *td, const void *ptr, - int tag_mode, ber_tlv_tag_t tag) + int tag_mode, ber_tlv_tag_t tag) { asn_CHOICE_specifics_t *specs = (asn_CHOICE_specifics_t *)td->specifics; int present; @@ -540,7 +540,7 @@ ber_tlv_tag_t CHOICE_outmost_tag(asn_TYPE_descriptor_t *td, const void *ptr, } return asn_TYPE_outmost_tag(elm->type, memb_ptr, elm->tag_mode, - elm->tag); + elm->tag); } else { @@ -549,7 +549,7 @@ ber_tlv_tag_t CHOICE_outmost_tag(asn_TYPE_descriptor_t *td, const void *ptr, } int CHOICE_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { asn_CHOICE_specifics_t *specs = (asn_CHOICE_specifics_t *)td->specifics; int present; @@ -557,7 +557,7 @@ int CHOICE_constraint(asn_TYPE_descriptor_t *td, const void *sptr, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -578,10 +578,10 @@ int CHOICE_constraint(asn_TYPE_descriptor_t *td, const void *sptr, { if (elm->optional) return 0; _ASN_CTFAIL(app_key, td, sptr, - "%s: mandatory CHOICE element %s " - "absent (%s:%d)", - td->name, elm->name, __FILE__, - __LINE__); + "%s: mandatory CHOICE element %s " + "absent (%s:%d)", + td->name, elm->name, __FILE__, + __LINE__); return -1; } } @@ -594,12 +594,12 @@ int CHOICE_constraint(asn_TYPE_descriptor_t *td, const void *sptr, if (elm->memb_constraints) { return elm->memb_constraints(elm->type, memb_ptr, ctfailcb, - app_key); + app_key); } else { int ret = elm->type->check_constraints(elm->type, memb_ptr, - ctfailcb, app_key); + ctfailcb, app_key); /* * Cannot inherit it eralier: * need to make sure we get the updated version. @@ -611,8 +611,8 @@ int CHOICE_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, - "%s: no CHOICE element given (%s:%d)", td->name, - __FILE__, __LINE__); + "%s: no CHOICE element given (%s:%d)", td->name, + __FILE__, __LINE__); return -1; } } @@ -632,9 +632,9 @@ int CHOICE_constraint(asn_TYPE_descriptor_t *td, const void *sptr, * Decode the XER (XML) data. */ asn_dec_rval_t CHOICE_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **struct_ptr, - const char *opt_mname, const void *buf_ptr, - size_t size) + asn_TYPE_descriptor_t *td, void **struct_ptr, + const char *opt_mname, const void *buf_ptr, + size_t size) { /* * Bring closer parts of structure description. @@ -709,17 +709,17 @@ asn_dec_rval_t CHOICE_decode_xer(asn_codec_ctx_t *opt_codec_ctx, /* Start/Continue decoding the inner member */ tmprval = elm->type->xer_decoder(opt_codec_ctx, elm->type, - memb_ptr2, elm->name, - buf_ptr, size); + memb_ptr2, elm->name, + buf_ptr, size); XER_ADVANCE(tmprval.consumed); ASN_DEBUG("XER/CHOICE: itdf: [%s] code=%d", elm->type->name, - tmprval.code); + tmprval.code); if (tmprval.code != RC_OK) RETURN(tmprval.code); assert(_fetch_present_idx(st, specs->pres_offset, - specs->pres_size) == 0); + specs->pres_size) == 0); /* Record what we've got */ _set_present_idx(st, specs->pres_offset, specs->pres_size, - edx + 1); + edx + 1); ctx->phase = 3; /* Fall through */ } @@ -737,29 +737,29 @@ asn_dec_rval_t CHOICE_decode_xer(asn_codec_ctx_t *opt_codec_ctx, ch_size = xer_next_token(&ctx->context, buf_ptr, size, &ch_type); switch (ch_size) { - case -1: - RETURN(RC_FAIL); - case 0: - RETURN(RC_WMORE); - default: - switch (ch_type) - { - case PXER_COMMENT: /* Got XML comment */ - case PXER_TEXT: /* Ignore free-standing text */ - XER_ADVANCE(ch_size); /* Skip silently */ - continue; - case PXER_TAG: - break; /* Check the rest down there */ - } + case -1: + RETURN(RC_FAIL); + case 0: + RETURN(RC_WMORE); + default: + switch (ch_type) + { + case PXER_COMMENT: /* Got XML comment */ + case PXER_TEXT: /* Ignore free-standing text */ + XER_ADVANCE(ch_size); /* Skip silently */ + continue; + case PXER_TAG: + break; /* Check the rest down there */ + } } tcv = xer_check_tag(buf_ptr, ch_size, xml_tag); ASN_DEBUG("XER/CHOICE checked [%c%c%c%c] vs [%s], tcv=%d", - ch_size > 0 ? ((const uint8_t *)buf_ptr)[0] : '?', - ch_size > 1 ? ((const uint8_t *)buf_ptr)[1] : '?', - ch_size > 2 ? ((const uint8_t *)buf_ptr)[2] : '?', - ch_size > 3 ? ((const uint8_t *)buf_ptr)[3] : '?', - xml_tag, tcv); + ch_size > 0 ? ((const uint8_t *)buf_ptr)[0] : '?', + ch_size > 1 ? ((const uint8_t *)buf_ptr)[1] : '?', + ch_size > 2 ? ((const uint8_t *)buf_ptr)[2] : '?', + ch_size > 3 ? ((const uint8_t *)buf_ptr)[3] : '?', + xml_tag, tcv); /* Skip the extensions section */ if (ctx->phase == 4) @@ -767,99 +767,99 @@ asn_dec_rval_t CHOICE_decode_xer(asn_codec_ctx_t *opt_codec_ctx, ASN_DEBUG("skip_unknown(%d, %ld)", tcv, (long)ctx->left); switch (xer_skip_unknown(tcv, &ctx->left)) { - case -1: - ctx->phase = 5; - RETURN(RC_FAIL); - continue; - case 1: - ctx->phase = 3; - /* Fall through */ - case 0: - XER_ADVANCE(ch_size); - continue; - case 2: - ctx->phase = 3; - break; + case -1: + ctx->phase = 5; + RETURN(RC_FAIL); + continue; + case 1: + ctx->phase = 3; + /* Fall through */ + case 0: + XER_ADVANCE(ch_size); + continue; + case 2: + ctx->phase = 3; + break; } } switch (tcv) { - case XCT_BOTH: - break; /* No CHOICE? */ - case XCT_CLOSING: - if (ctx->phase != 3) break; - XER_ADVANCE(ch_size); - ctx->phase = 5; /* Phase out */ - RETURN(RC_OK); - case XCT_OPENING: - if (ctx->phase == 0) - { - XER_ADVANCE(ch_size); - ctx->phase = 1; /* Processing body phase */ - continue; - } - /* Fall through */ - case XCT_UNKNOWN_OP: - case XCT_UNKNOWN_BO: + case XCT_BOTH: + break; /* No CHOICE? */ + case XCT_CLOSING: + if (ctx->phase != 3) break; + XER_ADVANCE(ch_size); + ctx->phase = 5; /* Phase out */ + RETURN(RC_OK); + case XCT_OPENING: + if (ctx->phase == 0) + { + XER_ADVANCE(ch_size); + ctx->phase = 1; /* Processing body phase */ + continue; + } + /* Fall through */ + case XCT_UNKNOWN_OP: + case XCT_UNKNOWN_BO: - if (ctx->phase != 1) break; /* Really unexpected */ + if (ctx->phase != 1) break; /* Really unexpected */ - /* + /* * Search which inner member corresponds to this tag. */ - for (edx = 0; edx < td->elements_count; edx++) - { - elm = &td->elements[edx]; - tcv = - xer_check_tag(buf_ptr, ch_size, elm->name); - switch (tcv) - { - case XCT_BOTH: - case XCT_OPENING: - /* + for (edx = 0; edx < td->elements_count; edx++) + { + elm = &td->elements[edx]; + tcv = + xer_check_tag(buf_ptr, ch_size, elm->name); + switch (tcv) + { + case XCT_BOTH: + case XCT_OPENING: + /* * Process this member. */ - ctx->step = edx; - ctx->phase = 2; - break; - case XCT_UNKNOWN_OP: - case XCT_UNKNOWN_BO: - continue; - default: - edx = td->elements_count; - break; /* Phase out */ - } - break; - } - if (edx != td->elements_count) continue; + ctx->step = edx; + ctx->phase = 2; + break; + case XCT_UNKNOWN_OP: + case XCT_UNKNOWN_BO: + continue; + default: + edx = td->elements_count; + break; /* Phase out */ + } + break; + } + if (edx != td->elements_count) continue; - /* It is expected extension */ - if (specs->ext_start != -1) - { - ASN_DEBUG("Got anticipated extension"); - /* + /* It is expected extension */ + if (specs->ext_start != -1) + { + ASN_DEBUG("Got anticipated extension"); + /* * Check for (XCT_BOTH or XCT_UNKNOWN_BO) * By using a mask. Only record a pure * tags. */ - if (tcv & XCT_CLOSING) - { - /* Found without body */ - ctx->phase = 3; /* Terminating */ - } - else - { - ctx->left = 1; - ctx->phase = 4; /* Skip ...'s */ - } - XER_ADVANCE(ch_size); - continue; - } + if (tcv & XCT_CLOSING) + { + /* Found without body */ + ctx->phase = 3; /* Terminating */ + } + else + { + ctx->left = 1; + ctx->phase = 4; /* Skip ...'s */ + } + XER_ADVANCE(ch_size); + continue; + } - /* Fall through */ - default: - break; + /* Fall through */ + default: + break; } ASN_DEBUG( @@ -878,8 +878,8 @@ asn_dec_rval_t CHOICE_decode_xer(asn_codec_ctx_t *opt_codec_ctx, } asn_enc_rval_t CHOICE_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { asn_CHOICE_specifics_t *specs = (asn_CHOICE_specifics_t *)td->specifics; asn_enc_rval_t er; @@ -920,7 +920,7 @@ asn_enc_rval_t CHOICE_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, _ASN_CALLBACK3("<", 1, mname, mlen, ">", 1); tmper = elm->type->xer_encoder(elm->type, memb_ptr, ilevel + 1, - flags, cb, app_key); + flags, cb, app_key); if (tmper.encoded == -1) return tmper; _ASN_CALLBACK3("", 1); @@ -936,9 +936,9 @@ cb_failed: } asn_dec_rval_t CHOICE_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd) { asn_CHOICE_specifics_t *specs = (asn_CHOICE_specifics_t *)td->specifics; asn_dec_rval_t rv; @@ -979,7 +979,7 @@ asn_dec_rval_t CHOICE_decode_uper(asn_codec_ctx_t *opt_codec_ctx, value = per_get_few_bits(pd, ct->range_bits); if (value < 0) _ASN_DECODE_STARVED; ASN_DEBUG("CHOICE %s got index %d in range %d", td->name, value, - ct->range_bits); + ct->range_bits); if (value > ct->upper_bound) _ASN_DECODE_FAILED; } else @@ -1013,23 +1013,23 @@ asn_dec_rval_t CHOICE_decode_uper(asn_codec_ctx_t *opt_codec_ctx, if (ct && ct->range_bits >= 0) { rv = elm->type->uper_decoder(opt_codec_ctx, elm->type, - elm->per_constraints, memb_ptr2, pd); + elm->per_constraints, memb_ptr2, pd); } else { rv = uper_open_type_get(opt_codec_ctx, elm->type, - elm->per_constraints, memb_ptr2, pd); + elm->per_constraints, memb_ptr2, pd); } if (rv.code != RC_OK) ASN_DEBUG("Failed to decode %s in %s (CHOICE) %d", elm->name, td->name, - rv.code); + rv.code); return rv; } asn_enc_rval_t CHOICE_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *sptr, asn_per_outp_t *po) + asn_per_constraints_t *constraints, + void *sptr, asn_per_outp_t *po) { asn_CHOICE_specifics_t *specs = (asn_CHOICE_specifics_t *)td->specifics; asn_TYPE_member_t *elm; /* CHOICE's element */ @@ -1100,7 +1100,7 @@ asn_enc_rval_t CHOICE_encode_uper(asn_TYPE_descriptor_t *td, _ASN_ENCODE_FAILED; return elm->type->uper_encoder(elm->type, elm->per_constraints, - memb_ptr, po); + memb_ptr, po); } else { @@ -1109,7 +1109,7 @@ asn_enc_rval_t CHOICE_encode_uper(asn_TYPE_descriptor_t *td, if (uper_put_nsnnwn(po, present - specs->ext_start)) _ASN_ENCODE_FAILED; if (uper_open_type_put(elm->type, elm->per_constraints, memb_ptr, - po)) + po)) _ASN_ENCODE_FAILED; rval.encoded = 0; _ASN_ENCODED_OK(rval); @@ -1117,7 +1117,7 @@ asn_enc_rval_t CHOICE_encode_uper(asn_TYPE_descriptor_t *td, } int CHOICE_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { asn_CHOICE_specifics_t *specs = (asn_CHOICE_specifics_t *)td->specifics; int present; @@ -1159,7 +1159,7 @@ int CHOICE_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, } return elm->type->print_struct(elm->type, memb_ptr, ilevel, cb, - app_key); + app_key); } else { @@ -1217,7 +1217,7 @@ void CHOICE_free(asn_TYPE_descriptor_t *td, void *ptr, int contents_only) * produce packed code. */ static int _fetch_present_idx(const void *struct_ptr, int pres_offset, - int pres_size) + int pres_size) { const void *present_ptr; int present; @@ -1226,43 +1226,43 @@ static int _fetch_present_idx(const void *struct_ptr, int pres_offset, switch (pres_size) { - case sizeof(int): - present = *(const int *)present_ptr; - break; - case sizeof(short): - present = *(const short *)present_ptr; - break; - case sizeof(char): - present = *(const char *)present_ptr; - break; - default: - /* ANSI C mandates enum to be equivalent to integer */ - assert(pres_size != sizeof(int)); - return 0; /* If not aborted, pass back safe value */ + case sizeof(int): + present = *(const int *)present_ptr; + break; + case sizeof(short): + present = *(const short *)present_ptr; + break; + case sizeof(char): + present = *(const char *)present_ptr; + break; + default: + /* ANSI C mandates enum to be equivalent to integer */ + assert(pres_size != sizeof(int)); + return 0; /* If not aborted, pass back safe value */ } return present; } static void _set_present_idx(void *struct_ptr, int pres_offset, int pres_size, - int present) + int present) { void *present_ptr; present_ptr = ((char *)struct_ptr) + pres_offset; switch (pres_size) { - case sizeof(int): - *(int *)present_ptr = present; - break; - case sizeof(short): - *(short *)present_ptr = present; - break; - case sizeof(char): - *(char *)present_ptr = present; - break; - default: - /* ANSI C mandates enum to be equivalent to integer */ - assert(pres_size != sizeof(int)); + case sizeof(int): + *(int *)present_ptr = present; + break; + case sizeof(short): + *(short *)present_ptr = present; + break; + case sizeof(char): + *(char *)present_ptr = present; + break; + default: + /* ANSI C mandates enum to be equivalent to integer */ + assert(pres_size != sizeof(int)); } } diff --git a/src/core/libs/supl/asn-rrlp/constr_SEQUENCE.c b/src/core/libs/supl/asn-rrlp/constr_SEQUENCE.c index 3b36c1fcd..fadc934f9 100644 --- a/src/core/libs/supl/asn-rrlp/constr_SEQUENCE.c +++ b/src/core/libs/supl/asn-rrlp/constr_SEQUENCE.c @@ -125,8 +125,8 @@ static int _t2e_cmp(const void *ap, const void *bp) * The decoder of the SEQUENCE type. */ asn_dec_rval_t SEQUENCE_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **struct_ptr, - const void *ptr, size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, void **struct_ptr, + const void *ptr, size_t size, int tag_mode) { /* * Bring closer parts of structure description. @@ -170,34 +170,34 @@ asn_dec_rval_t SEQUENCE_decode_ber(asn_codec_ctx_t *opt_codec_ctx, */ switch (ctx->phase) { - case 0: - /* + case 0: + /* * PHASE 0. * Check that the set of tags associated with given structure * perfectly fits our expectations. */ - rval = ber_check_tags(opt_codec_ctx, td, ctx, ptr, size, - tag_mode, 1, &ctx->left, 0); - if (rval.code != RC_OK) - { - ASN_DEBUG("%s tagging check failed: %d", td->name, - rval.code); - return rval; - } + rval = ber_check_tags(opt_codec_ctx, td, ctx, ptr, size, + tag_mode, 1, &ctx->left, 0); + if (rval.code != RC_OK) + { + ASN_DEBUG("%s tagging check failed: %d", td->name, + rval.code); + return rval; + } - if (ctx->left >= 0) - ctx->left += rval.consumed; /* ?Subtracted below! */ - ADVANCE(rval.consumed); + if (ctx->left >= 0) + ctx->left += rval.consumed; /* ?Subtracted below! */ + ADVANCE(rval.consumed); - NEXT_PHASE(ctx); + NEXT_PHASE(ctx); - ASN_DEBUG("Structure consumes %ld bytes, buffer %ld", - (long)ctx->left, (long)size); + ASN_DEBUG("Structure consumes %ld bytes, buffer %ld", + (long)ctx->left, (long)size); - /* Fall through */ - case 1: - /* + /* Fall through */ + case 1: + /* * PHASE 1. * From the place where we've left it previously, * try to decode the next member from the list of @@ -207,380 +207,380 @@ asn_dec_rval_t SEQUENCE_decode_ber(asn_codec_ctx_t *opt_codec_ctx, * that member: * step = ( * 2 + ). */ - for (edx = (ctx->step >> 1); edx < td->elements_count; - edx++, ctx->step = (ctx->step & ~1) + 2) - { - void *memb_ptr; /* Pointer to the member */ - void **memb_ptr2; /* Pointer to that pointer */ - ssize_t tag_len; /* Length of TLV's T */ - int opt_edx_end; /* Next non-optional element */ - int use_bsearch; - int n; + for (edx = (ctx->step >> 1); edx < td->elements_count; + edx++, ctx->step = (ctx->step & ~1) + 2) + { + void *memb_ptr; /* Pointer to the member */ + void **memb_ptr2; /* Pointer to that pointer */ + ssize_t tag_len; /* Length of TLV's T */ + int opt_edx_end; /* Next non-optional element */ + int use_bsearch; + int n; - if (ctx->step & 1) goto microphase2; + if (ctx->step & 1) goto microphase2; - /* + /* * MICROPHASE 1: Synchronize decoding. */ - ASN_DEBUG( - "In %s SEQUENCE left %d, edx=%d flags=%d" - " opt=%d ec=%d", - td->name, (int)ctx->left, edx, elements[edx].flags, - elements[edx].optional, td->elements_count); + ASN_DEBUG( + "In %s SEQUENCE left %d, edx=%d flags=%d" + " opt=%d ec=%d", + td->name, (int)ctx->left, edx, elements[edx].flags, + elements[edx].optional, td->elements_count); - if (ctx->left == 0 /* No more stuff is expected */ - && ( - /* Explicit OPTIONAL specification reaches + if (ctx->left == 0 /* No more stuff is expected */ + && ( + /* Explicit OPTIONAL specification reaches the end */ - (edx + elements[edx].optional == - td->elements_count) || - /* All extensions are optional */ - (IN_EXTENSION_GROUP(specs, edx) && - specs->ext_before > td->elements_count))) - { - ASN_DEBUG("End of SEQUENCE %s", td->name); - /* + (edx + elements[edx].optional == + td->elements_count) || + /* All extensions are optional */ + (IN_EXTENSION_GROUP(specs, edx) && + specs->ext_before > td->elements_count))) + { + ASN_DEBUG("End of SEQUENCE %s", td->name); + /* * Found the legitimate end of the structure. */ - PHASE_OUT(ctx); - RETURN(RC_OK); - } + PHASE_OUT(ctx); + RETURN(RC_OK); + } - /* + /* * Fetch the T from TLV. */ - tag_len = ber_fetch_tag(ptr, LEFT, &tlv_tag); - ASN_DEBUG( - "Current tag in %s SEQUENCE for element %d " - "(%s) is %s encoded in %d bytes, of frame %ld", - td->name, edx, elements[edx].name, - ber_tlv_tag_string(tlv_tag), (int)tag_len, - (long)LEFT); - switch (tag_len) - { - case 0: - if (!SIZE_VIOLATION) RETURN(RC_WMORE); - /* Fall through */ - case -1: - RETURN(RC_FAIL); - } + tag_len = ber_fetch_tag(ptr, LEFT, &tlv_tag); + ASN_DEBUG( + "Current tag in %s SEQUENCE for element %d " + "(%s) is %s encoded in %d bytes, of frame %ld", + td->name, edx, elements[edx].name, + ber_tlv_tag_string(tlv_tag), (int)tag_len, + (long)LEFT); + switch (tag_len) + { + case 0: + if (!SIZE_VIOLATION) RETURN(RC_WMORE); + /* Fall through */ + case -1: + RETURN(RC_FAIL); + } - if (ctx->left < 0 && ((const uint8_t *)ptr)[0] == 0) - { - if (LEFT < 2) - { - if (SIZE_VIOLATION) - RETURN(RC_FAIL); - else - RETURN(RC_WMORE); - } - else if (((const uint8_t *)ptr)[1] == 0) - { - ASN_DEBUG("edx = %d, opt = %d, ec=%d", - edx, elements[edx].optional, - td->elements_count); - if ((edx + elements[edx].optional == - td->elements_count) || - (IN_EXTENSION_GROUP(specs, edx) && - specs->ext_before > - td->elements_count)) - { - /* + if (ctx->left < 0 && ((const uint8_t *)ptr)[0] == 0) + { + if (LEFT < 2) + { + if (SIZE_VIOLATION) + RETURN(RC_FAIL); + else + RETURN(RC_WMORE); + } + else if (((const uint8_t *)ptr)[1] == 0) + { + ASN_DEBUG("edx = %d, opt = %d, ec=%d", + edx, elements[edx].optional, + td->elements_count); + if ((edx + elements[edx].optional == + td->elements_count) || + (IN_EXTENSION_GROUP(specs, edx) && + specs->ext_before > + td->elements_count)) + { + /* * Yeah, baby! Found the * terminator of the indefinite * length structure. */ - /* + /* * Proceed to the canonical * finalization function. * No advancing is necessary. */ - goto phase3; - } - } - } + goto phase3; + } + } + } - /* + /* * Find the next available type with this tag. */ - use_bsearch = 0; - opt_edx_end = edx + elements[edx].optional + 1; - if (opt_edx_end > td->elements_count) - opt_edx_end = td->elements_count; /* Cap */ - else if (opt_edx_end - edx > 8) - { - /* Limit the scope of linear search... */ - opt_edx_end = edx + 8; - use_bsearch = 1; - /* ... and resort to bsearch() */ - } - for (n = edx; n < opt_edx_end; n++) - { - if (BER_TAGS_EQUAL(tlv_tag, elements[n].tag)) - { - /* + use_bsearch = 0; + opt_edx_end = edx + elements[edx].optional + 1; + if (opt_edx_end > td->elements_count) + opt_edx_end = td->elements_count; /* Cap */ + else if (opt_edx_end - edx > 8) + { + /* Limit the scope of linear search... */ + opt_edx_end = edx + 8; + use_bsearch = 1; + /* ... and resort to bsearch() */ + } + for (n = edx; n < opt_edx_end; n++) + { + if (BER_TAGS_EQUAL(tlv_tag, elements[n].tag)) + { + /* * Found element corresponding to the * tag being looked at. Reposition over * the right element. */ - edx = n; - ctx->step = 1 + 2 * edx; /* Remember! */ - goto microphase2; - } - else if (elements[n].flags & ATF_OPEN_TYPE) - { - /* + edx = n; + ctx->step = 1 + 2 * edx; /* Remember! */ + goto microphase2; + } + else if (elements[n].flags & ATF_OPEN_TYPE) + { + /* * This is the ANY type, which may bear * any flag whatsoever. */ - edx = n; - ctx->step = 1 + 2 * edx; /* Remember! */ - goto microphase2; - } - else if (elements[n].tag == (ber_tlv_tag_t)-1) - { - use_bsearch = 1; - break; - } - } - if (use_bsearch) - { - /* + edx = n; + ctx->step = 1 + 2 * edx; /* Remember! */ + goto microphase2; + } + else if (elements[n].tag == (ber_tlv_tag_t)-1) + { + use_bsearch = 1; + break; + } + } + if (use_bsearch) + { + /* * Resort to a binary search over * sorted array of tags. */ - asn_TYPE_tag2member_t *t2m; - asn_TYPE_tag2member_t key; - key.el_tag = tlv_tag; - key.el_no = edx; - t2m = (asn_TYPE_tag2member_t *)bsearch( - &key, specs->tag2el, specs->tag2el_count, - sizeof(specs->tag2el[0]), _t2e_cmp); - if (t2m) - { - asn_TYPE_tag2member_t *best = 0; - asn_TYPE_tag2member_t *t2m_f; - asn_TYPE_tag2member_t *t2m_l; - int edx_max = - edx + elements[edx].optional; - /* + asn_TYPE_tag2member_t *t2m; + asn_TYPE_tag2member_t key; + key.el_tag = tlv_tag; + key.el_no = edx; + t2m = (asn_TYPE_tag2member_t *)bsearch( + &key, specs->tag2el, specs->tag2el_count, + sizeof(specs->tag2el[0]), _t2e_cmp); + if (t2m) + { + asn_TYPE_tag2member_t *best = 0; + asn_TYPE_tag2member_t *t2m_f; + asn_TYPE_tag2member_t *t2m_l; + int edx_max = + edx + elements[edx].optional; + /* * Rewind to the first element with that * tag, `cause bsearch() does not * guarantee order. */ - t2m_f = t2m + t2m->toff_first; - t2m_l = t2m + t2m->toff_last; - for (t2m = t2m_f; t2m <= t2m_l; t2m++) - { - if (t2m->el_no > edx_max) break; - if (t2m->el_no < edx) continue; - best = t2m; - } - if (best) - { - edx = best->el_no; - ctx->step = 1 + 2 * edx; - goto microphase2; - } - } - n = opt_edx_end; - } - if (n == opt_edx_end) - { - /* + t2m_f = t2m + t2m->toff_first; + t2m_l = t2m + t2m->toff_last; + for (t2m = t2m_f; t2m <= t2m_l; t2m++) + { + if (t2m->el_no > edx_max) break; + if (t2m->el_no < edx) continue; + best = t2m; + } + if (best) + { + edx = best->el_no; + ctx->step = 1 + 2 * edx; + goto microphase2; + } + } + n = opt_edx_end; + } + if (n == opt_edx_end) + { + /* * If tag is unknown, it may be either * an unknown (thus, incorrect) tag, * or an extension (...), * or an end of the indefinite-length structure. */ - if (!IN_EXTENSION_GROUP( - specs, edx + elements[edx].optional)) - { - ASN_DEBUG("Unexpected tag %s (at %d)", - ber_tlv_tag_string(tlv_tag), - edx); - ASN_DEBUG("Expected tag %s (%s)%s", - ber_tlv_tag_string( - elements[edx].tag), - elements[edx].name, - elements[edx].optional - ? " or alternatives" - : ""); - RETURN(RC_FAIL); - } - else - { - /* Skip this tag */ - ssize_t skip; - edx += elements[edx].optional; + if (!IN_EXTENSION_GROUP( + specs, edx + elements[edx].optional)) + { + ASN_DEBUG("Unexpected tag %s (at %d)", + ber_tlv_tag_string(tlv_tag), + edx); + ASN_DEBUG("Expected tag %s (%s)%s", + ber_tlv_tag_string( + elements[edx].tag), + elements[edx].name, + elements[edx].optional + ? " or alternatives" + : ""); + RETURN(RC_FAIL); + } + else + { + /* Skip this tag */ + ssize_t skip; + edx += elements[edx].optional; - ASN_DEBUG( - "Skipping unexpected %s (at %d)", - ber_tlv_tag_string(tlv_tag), edx); - skip = ber_skip_length( - opt_codec_ctx, - BER_TLV_CONSTRUCTED(ptr), - (const char *)ptr + tag_len, - LEFT - tag_len); - ASN_DEBUG("Skip length %d in %s", - (int)skip, td->name); - switch (skip) - { - case 0: - if (!SIZE_VIOLATION) - RETURN(RC_WMORE); - /* Fall through */ - case -1: - RETURN(RC_FAIL); - } + ASN_DEBUG( + "Skipping unexpected %s (at %d)", + ber_tlv_tag_string(tlv_tag), edx); + skip = ber_skip_length( + opt_codec_ctx, + BER_TLV_CONSTRUCTED(ptr), + (const char *)ptr + tag_len, + LEFT - tag_len); + ASN_DEBUG("Skip length %d in %s", + (int)skip, td->name); + switch (skip) + { + case 0: + if (!SIZE_VIOLATION) + RETURN(RC_WMORE); + /* Fall through */ + case -1: + RETURN(RC_FAIL); + } - ADVANCE(skip + tag_len); - ctx->step -= 2; - edx--; - continue; /* Try again with the next tag + ADVANCE(skip + tag_len); + ctx->step -= 2; + edx--; + continue; /* Try again with the next tag */ - } - } + } + } - /* + /* * MICROPHASE 2: Invoke the member-specific decoder. */ - ctx->step |= 1; /* Confirm entering next microphase */ - microphase2: - ASN_DEBUG("Inside SEQUENCE %s MF2", td->name); + ctx->step |= 1; /* Confirm entering next microphase */ + microphase2: + ASN_DEBUG("Inside SEQUENCE %s MF2", td->name); - /* + /* * Compute the position of the member inside a * structure, and also a type of containment (it may be * contained as pointer or using inline inclusion). */ - if (elements[edx].flags & ATF_POINTER) - { - /* Member is a pointer to another structure */ - memb_ptr2 = - (void **)((char *)st + - elements[edx].memb_offset); - } - else - { - /* + if (elements[edx].flags & ATF_POINTER) + { + /* Member is a pointer to another structure */ + memb_ptr2 = + (void **)((char *)st + + elements[edx].memb_offset); + } + else + { + /* * A pointer to a pointer * holding the start of the structure */ - memb_ptr = - (char *)st + elements[edx].memb_offset; - memb_ptr2 = &memb_ptr; - } - /* + memb_ptr = + (char *)st + elements[edx].memb_offset; + memb_ptr2 = &memb_ptr; + } + /* * Invoke the member fetch routine according to member's * type */ - rval = elements[edx].type->ber_decoder( - opt_codec_ctx, elements[edx].type, memb_ptr2, ptr, - LEFT, elements[edx].tag_mode); - ASN_DEBUG( - "In %s SEQUENCE decoded %d %s of %d " - "in %d bytes rval.code %d, size=%d", - td->name, edx, elements[edx].type->name, (int)LEFT, - (int)rval.consumed, rval.code, (int)size); - switch (rval.code) - { - case RC_OK: - break; - case RC_WMORE: /* More data expected */ - if (!SIZE_VIOLATION) - { - ADVANCE(rval.consumed); - RETURN(RC_WMORE); - } - ASN_DEBUG( - "Size violation (c->l=%ld <= s=%ld)", - (long)ctx->left, (long)size); - /* Fall through */ - case RC_FAIL: /* Fatal error */ - RETURN(RC_FAIL); - } /* switch(rval) */ + rval = elements[edx].type->ber_decoder( + opt_codec_ctx, elements[edx].type, memb_ptr2, ptr, + LEFT, elements[edx].tag_mode); + ASN_DEBUG( + "In %s SEQUENCE decoded %d %s of %d " + "in %d bytes rval.code %d, size=%d", + td->name, edx, elements[edx].type->name, (int)LEFT, + (int)rval.consumed, rval.code, (int)size); + switch (rval.code) + { + case RC_OK: + break; + case RC_WMORE: /* More data expected */ + if (!SIZE_VIOLATION) + { + ADVANCE(rval.consumed); + RETURN(RC_WMORE); + } + ASN_DEBUG( + "Size violation (c->l=%ld <= s=%ld)", + (long)ctx->left, (long)size); + /* Fall through */ + case RC_FAIL: /* Fatal error */ + RETURN(RC_FAIL); + } /* switch(rval) */ - ADVANCE(rval.consumed); - } /* for(all structure members) */ + ADVANCE(rval.consumed); + } /* for(all structure members) */ - phase3: - ctx->phase = 3; - case 3: /* 00 and other tags expected */ - case 4: /* only 00's expected */ + phase3: + ctx->phase = 3; + case 3: /* 00 and other tags expected */ + case 4: /* only 00's expected */ - ASN_DEBUG("SEQUENCE %s Leftover: %ld, size = %ld", td->name, - (long)ctx->left, (long)size); + ASN_DEBUG("SEQUENCE %s Leftover: %ld, size = %ld", td->name, + (long)ctx->left, (long)size); - /* + /* * Skip everything until the end of the SEQUENCE. */ - while (ctx->left) - { - ssize_t tl; - ssize_t ll; + while (ctx->left) + { + ssize_t tl; + ssize_t ll; - tl = ber_fetch_tag(ptr, LEFT, &tlv_tag); - switch (tl) - { - case 0: - if (!SIZE_VIOLATION) RETURN(RC_WMORE); - /* Fall through */ - case -1: - RETURN(RC_FAIL); - } + tl = ber_fetch_tag(ptr, LEFT, &tlv_tag); + switch (tl) + { + case 0: + if (!SIZE_VIOLATION) RETURN(RC_WMORE); + /* Fall through */ + case -1: + RETURN(RC_FAIL); + } - /* + /* * If expected <0><0>... */ - if (ctx->left < 0 && ((const uint8_t *)ptr)[0] == 0) - { - if (LEFT < 2) - { - if (SIZE_VIOLATION) - RETURN(RC_FAIL); - else - RETURN(RC_WMORE); - } - else if (((const uint8_t *)ptr)[1] == 0) - { - /* + if (ctx->left < 0 && ((const uint8_t *)ptr)[0] == 0) + { + if (LEFT < 2) + { + if (SIZE_VIOLATION) + RETURN(RC_FAIL); + else + RETURN(RC_WMORE); + } + else if (((const uint8_t *)ptr)[1] == 0) + { + /* * Correctly finished with <0><0>. */ - ADVANCE(2); - ctx->left++; - ctx->phase = 4; - continue; - } - } + ADVANCE(2); + ctx->left++; + ctx->phase = 4; + continue; + } + } - if (!IN_EXTENSION_GROUP(specs, td->elements_count) || - ctx->phase == 4) - { - ASN_DEBUG( - "Unexpected continuation " - "of a non-extensible type " - "%s (SEQUENCE): %s", - td->name, ber_tlv_tag_string(tlv_tag)); - RETURN(RC_FAIL); - } + if (!IN_EXTENSION_GROUP(specs, td->elements_count) || + ctx->phase == 4) + { + ASN_DEBUG( + "Unexpected continuation " + "of a non-extensible type " + "%s (SEQUENCE): %s", + td->name, ber_tlv_tag_string(tlv_tag)); + RETURN(RC_FAIL); + } - ll = ber_skip_length(opt_codec_ctx, - BER_TLV_CONSTRUCTED(ptr), - (const char *)ptr + tl, LEFT - tl); - switch (ll) - { - case 0: - if (!SIZE_VIOLATION) RETURN(RC_WMORE); - /* Fall through */ - case -1: - RETURN(RC_FAIL); - } + ll = ber_skip_length(opt_codec_ctx, + BER_TLV_CONSTRUCTED(ptr), + (const char *)ptr + tl, LEFT - tl); + switch (ll) + { + case 0: + if (!SIZE_VIOLATION) RETURN(RC_WMORE); + /* Fall through */ + case -1: + RETURN(RC_FAIL); + } - ADVANCE(tl + ll); - } + ADVANCE(tl + ll); + } - PHASE_OUT(ctx); + PHASE_OUT(ctx); } RETURN(RC_OK); @@ -590,8 +590,8 @@ asn_dec_rval_t SEQUENCE_decode_ber(asn_codec_ctx_t *opt_codec_ctx, * The DER encoder of the SEQUENCE type. */ asn_enc_rval_t SEQUENCE_encode_der(asn_TYPE_descriptor_t *td, void *sptr, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { size_t computed_size = 0; asn_enc_rval_t erval; @@ -622,11 +622,11 @@ asn_enc_rval_t SEQUENCE_encode_der(asn_TYPE_descriptor_t *td, void *sptr, memb_ptr = (void *)((char *)sptr + elm->memb_offset); } erval = elm->type->der_encoder(elm->type, memb_ptr, elm->tag_mode, - elm->tag, 0, 0); + elm->tag, 0, 0); if (erval.encoded == -1) return erval; computed_size += erval.encoded; ASN_DEBUG("Member %d %s estimated %ld bytes", edx, elm->name, - (long)erval.encoded); + (long)erval.encoded); } /* @@ -662,7 +662,7 @@ asn_enc_rval_t SEQUENCE_encode_der(asn_TYPE_descriptor_t *td, void *sptr, if (tmperval.encoded == -1) return tmperval; computed_size -= tmperval.encoded; ASN_DEBUG("Member %d %s of SEQUENCE %s encoded in %ld bytes", edx, - elm->name, td->name, (long)tmperval.encoded); + elm->name, td->name, (long)tmperval.encoded); } if (computed_size != 0) @@ -689,9 +689,9 @@ asn_enc_rval_t SEQUENCE_encode_der(asn_TYPE_descriptor_t *td, void *sptr, * Decode the XER (XML) data. */ asn_dec_rval_t SEQUENCE_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **struct_ptr, - const char *opt_mname, const void *buf_ptr, - size_t size) + asn_TYPE_descriptor_t *td, void **struct_ptr, + const char *opt_mname, const void *buf_ptr, + size_t size) { /* * Bring closer parts of structure description. @@ -766,14 +766,14 @@ asn_dec_rval_t SEQUENCE_decode_xer(asn_codec_ctx_t *opt_codec_ctx, /* Invoke the inner type decoder, m.b. multiple times */ tmprval = elm->type->xer_decoder(opt_codec_ctx, elm->type, - memb_ptr2, elm->name, - buf_ptr, size); + memb_ptr2, elm->name, + buf_ptr, size); XER_ADVANCE(tmprval.consumed); if (tmprval.code != RC_OK) RETURN(tmprval.code); ctx->phase = 1; /* Back to body processing */ ctx->step = ++edx; ASN_DEBUG("XER/SEQUENCE phase => %d, step => %d", - ctx->phase, ctx->step); + ctx->phase, ctx->step); /* Fall through */ } @@ -783,173 +783,173 @@ asn_dec_rval_t SEQUENCE_decode_xer(asn_codec_ctx_t *opt_codec_ctx, ch_size = xer_next_token(&ctx->context, buf_ptr, size, &ch_type); switch (ch_size) { - case -1: - RETURN(RC_FAIL); - case 0: - RETURN(RC_WMORE); - default: - switch (ch_type) - { - case PXER_COMMENT: /* Got XML comment */ - case PXER_TEXT: /* Ignore free-standing text */ - XER_ADVANCE(ch_size); /* Skip silently */ - continue; - case PXER_TAG: - break; /* Check the rest down there */ - } + case -1: + RETURN(RC_FAIL); + case 0: + RETURN(RC_WMORE); + default: + switch (ch_type) + { + case PXER_COMMENT: /* Got XML comment */ + case PXER_TEXT: /* Ignore free-standing text */ + XER_ADVANCE(ch_size); /* Skip silently */ + continue; + case PXER_TAG: + break; /* Check the rest down there */ + } } tcv = xer_check_tag(buf_ptr, ch_size, xml_tag); ASN_DEBUG("XER/SEQUENCE: tcv = %d, ph=%d [%s]", tcv, ctx->phase, - xml_tag); + xml_tag); /* Skip the extensions section */ if (ctx->phase == 3) { switch (xer_skip_unknown(tcv, &ctx->left)) { - case -1: - ctx->phase = 4; - RETURN(RC_FAIL); - case 0: - XER_ADVANCE(ch_size); - continue; - case 1: - XER_ADVANCE(ch_size); - ctx->phase = 1; - continue; - case 2: - ctx->phase = 1; - break; + case -1: + ctx->phase = 4; + RETURN(RC_FAIL); + case 0: + XER_ADVANCE(ch_size); + continue; + case 1: + XER_ADVANCE(ch_size); + ctx->phase = 1; + continue; + case 2: + ctx->phase = 1; + break; } } switch (tcv) { - case XCT_CLOSING: - if (ctx->phase == 0) break; - ctx->phase = 0; - /* Fall through */ - case XCT_BOTH: - if (ctx->phase == 0) - { - if (edx >= td->elements_count || - /* Explicit OPTIONAL specs reaches the end + case XCT_CLOSING: + if (ctx->phase == 0) break; + ctx->phase = 0; + /* Fall through */ + case XCT_BOTH: + if (ctx->phase == 0) + { + if (edx >= td->elements_count || + /* Explicit OPTIONAL specs reaches the end */ - (edx + elements[edx].optional == - td->elements_count) || - /* All extensions are optional */ - (IN_EXTENSION_GROUP(specs, edx) && - specs->ext_before > td->elements_count)) - { - XER_ADVANCE(ch_size); - ctx->phase = 4; /* Phase out */ - RETURN(RC_OK); - } - else - { - ASN_DEBUG( - "Premature end of XER SEQUENCE"); - RETURN(RC_FAIL); - } - } - /* Fall through */ - case XCT_OPENING: - if (ctx->phase == 0) - { - XER_ADVANCE(ch_size); - ctx->phase = 1; /* Processing body phase */ - continue; - } - /* Fall through */ - case XCT_UNKNOWN_OP: - case XCT_UNKNOWN_BO: + (edx + elements[edx].optional == + td->elements_count) || + /* All extensions are optional */ + (IN_EXTENSION_GROUP(specs, edx) && + specs->ext_before > td->elements_count)) + { + XER_ADVANCE(ch_size); + ctx->phase = 4; /* Phase out */ + RETURN(RC_OK); + } + else + { + ASN_DEBUG( + "Premature end of XER SEQUENCE"); + RETURN(RC_FAIL); + } + } + /* Fall through */ + case XCT_OPENING: + if (ctx->phase == 0) + { + XER_ADVANCE(ch_size); + ctx->phase = 1; /* Processing body phase */ + continue; + } + /* Fall through */ + case XCT_UNKNOWN_OP: + case XCT_UNKNOWN_BO: - ASN_DEBUG("XER/SEQUENCE: tcv=%d, ph=%d, edx=%d", tcv, - ctx->phase, edx); - if (ctx->phase != 1) - { - break; /* Really unexpected */ - } + ASN_DEBUG("XER/SEQUENCE: tcv=%d, ph=%d, edx=%d", tcv, + ctx->phase, edx); + if (ctx->phase != 1) + { + break; /* Really unexpected */ + } - if (edx < td->elements_count) - { - /* + if (edx < td->elements_count) + { + /* * Search which member corresponds to this tag. */ - edx_end = edx + elements[edx].optional + 1; - if (edx_end > td->elements_count) - edx_end = td->elements_count; - for (n = edx; n < edx_end; n++) - { - elm = &td->elements[n]; - tcv = xer_check_tag(buf_ptr, ch_size, - elm->name); - switch (tcv) - { - case XCT_BOTH: - case XCT_OPENING: - /* + edx_end = edx + elements[edx].optional + 1; + if (edx_end > td->elements_count) + edx_end = td->elements_count; + for (n = edx; n < edx_end; n++) + { + elm = &td->elements[n]; + tcv = xer_check_tag(buf_ptr, ch_size, + elm->name); + switch (tcv) + { + case XCT_BOTH: + case XCT_OPENING: + /* * Process this member. */ - ctx->step = edx = n; - ctx->phase = 2; - break; - case XCT_UNKNOWN_OP: - case XCT_UNKNOWN_BO: - continue; - default: - n = edx_end; - break; /* Phase out */ - } - break; - } - if (n != edx_end) continue; - } - else - { - ASN_DEBUG("Out of defined members: %d/%d", edx, - td->elements_count); - } + ctx->step = edx = n; + ctx->phase = 2; + break; + case XCT_UNKNOWN_OP: + case XCT_UNKNOWN_BO: + continue; + default: + n = edx_end; + break; /* Phase out */ + } + break; + } + if (n != edx_end) continue; + } + else + { + ASN_DEBUG("Out of defined members: %d/%d", edx, + td->elements_count); + } - /* It is expected extension */ - if (IN_EXTENSION_GROUP( - specs, edx + (edx < td->elements_count - ? elements[edx].optional - : 0))) - { - ASN_DEBUG("Got anticipated extension at %d", - edx); - /* + /* It is expected extension */ + if (IN_EXTENSION_GROUP( + specs, edx + (edx < td->elements_count + ? elements[edx].optional + : 0))) + { + ASN_DEBUG("Got anticipated extension at %d", + edx); + /* * Check for (XCT_BOTH or XCT_UNKNOWN_BO) * By using a mask. Only record a pure * tags. */ - if (tcv & XCT_CLOSING) - { - /* Found without body */ - } - else - { - ctx->left = 1; - ctx->phase = 3; /* Skip ...'s */ - } - XER_ADVANCE(ch_size); - continue; - } + if (tcv & XCT_CLOSING) + { + /* Found without body */ + } + else + { + ctx->left = 1; + ctx->phase = 3; /* Skip ...'s */ + } + XER_ADVANCE(ch_size); + continue; + } - /* Fall through */ - default: - break; + /* Fall through */ + default: + break; } ASN_DEBUG("Unexpected XML tag in SEQUENCE [%c%c%c%c%c%c]", - size > 0 ? ((const char *)buf_ptr)[0] : '.', - size > 1 ? ((const char *)buf_ptr)[1] : '.', - size > 2 ? ((const char *)buf_ptr)[2] : '.', - size > 3 ? ((const char *)buf_ptr)[3] : '.', - size > 4 ? ((const char *)buf_ptr)[4] : '.', - size > 5 ? ((const char *)buf_ptr)[5] : '.'); + size > 0 ? ((const char *)buf_ptr)[0] : '.', + size > 1 ? ((const char *)buf_ptr)[1] : '.', + size > 2 ? ((const char *)buf_ptr)[2] : '.', + size > 3 ? ((const char *)buf_ptr)[3] : '.', + size > 4 ? ((const char *)buf_ptr)[4] : '.', + size > 5 ? ((const char *)buf_ptr)[5] : '.'); break; } @@ -958,8 +958,8 @@ asn_dec_rval_t SEQUENCE_decode_xer(asn_codec_ctx_t *opt_codec_ctx, } asn_enc_rval_t SEQUENCE_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { asn_enc_rval_t er; int xcan = (flags & XER_F_CANONICAL); @@ -997,7 +997,7 @@ asn_enc_rval_t SEQUENCE_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, /* Print the member itself */ tmper = elm->type->xer_encoder(elm->type, memb_ptr, ilevel + 1, - flags, cb, app_key); + flags, cb, app_key); if (tmper.encoded == -1) return tmper; _ASN_CALLBACK3("", 1); @@ -1012,7 +1012,7 @@ cb_failed: } int SEQUENCE_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { int edx; int ret; @@ -1056,7 +1056,7 @@ int SEQUENCE_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, /* Print the member itself */ ret = elm->type->print_struct(elm->type, memb_ptr, ilevel + 1, cb, - app_key); + app_key); if (ret) return ret; } @@ -1097,14 +1097,14 @@ void SEQUENCE_free(asn_TYPE_descriptor_t *td, void *sptr, int contents_only) } int SEQUENCE_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { int edx; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -1139,13 +1139,13 @@ int SEQUENCE_constraint(asn_TYPE_descriptor_t *td, const void *sptr, if (elm->memb_constraints) { int ret = elm->memb_constraints(elm->type, memb_ptr, - ctfailcb, app_key); + ctfailcb, app_key); if (ret) return ret; } else { int ret = elm->type->check_constraints(elm->type, memb_ptr, - ctfailcb, app_key); + ctfailcb, app_key); if (ret) return ret; /* * Cannot inherit it earlier: @@ -1159,9 +1159,9 @@ int SEQUENCE_constraint(asn_TYPE_descriptor_t *td, const void *sptr, } asn_dec_rval_t SEQUENCE_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd) { asn_SEQUENCE_specifics_t *specs = (asn_SEQUENCE_specifics_t *)td->specifics; void *st = *sptr; /* Target structure. */ @@ -1209,7 +1209,7 @@ asn_dec_rval_t SEQUENCE_decode_uper(asn_codec_ctx_t *opt_codec_ctx, opmd.buffer = opres; opmd.nbits = specs->roms_count; ASN_DEBUG("Read in presence bitmap for %s of %d bits (%x..)", - td->name, specs->roms_count, *opres); + td->name, specs->roms_count, *opres); } else { @@ -1243,8 +1243,8 @@ asn_dec_rval_t SEQUENCE_decode_uper(asn_codec_ctx_t *opt_codec_ctx, { int present = per_get_few_bits(&opmd, 1); ASN_DEBUG("Member %s->%s is optional, p=%d (%d->%d)", - td->name, elm->name, present, (int)opmd.nboff, - (int)opmd.nbits); + td->name, elm->name, present, (int)opmd.nboff, + (int)opmd.nbits); if (present == 0) { /* This element is not present */ @@ -1267,7 +1267,7 @@ asn_dec_rval_t SEQUENCE_decode_uper(asn_codec_ctx_t *opt_codec_ctx, /* Fetch the member from the stream */ ASN_DEBUG("Decoding member %s in %s", elm->name, td->name); rv = elm->type->uper_decoder(opt_codec_ctx, elm->type, - elm->per_constraints, memb_ptr2, pd); + elm->per_constraints, memb_ptr2, pd); if (rv.code != RC_OK) { ASN_DEBUG("Failed decode %s in %s", elm->name, td->name); @@ -1307,7 +1307,7 @@ asn_dec_rval_t SEQUENCE_decode_uper(asn_codec_ctx_t *opt_codec_ctx, epmd.buffer = epres; epmd.nbits = bmlength; ASN_DEBUG("Read in extensions bitmap for %s of %d bits (%x..)", - td->name, bmlength, *epres); + td->name, bmlength, *epres); /* Go over extensions and read them in */ for (edx = specs->ext_after + 1; edx < td->elements_count; edx++) @@ -1343,10 +1343,10 @@ asn_dec_rval_t SEQUENCE_decode_uper(asn_codec_ctx_t *opt_codec_ctx, } ASN_DEBUG("Decoding member %s in %s %p", elm->name, - td->name, *memb_ptr2); + td->name, *memb_ptr2); rv = uper_open_type_get(opt_codec_ctx, elm->type, - elm->per_constraints, memb_ptr2, pd); + elm->per_constraints, memb_ptr2, pd); if (rv.code != RC_OK) { FREEMEM(epres); @@ -1361,16 +1361,16 @@ asn_dec_rval_t SEQUENCE_decode_uper(asn_codec_ctx_t *opt_codec_ctx, ASN_DEBUG("Getting overflow extensions"); switch (per_get_few_bits(&epmd, 1)) { - case -1: - break; - case 0: - continue; - default: - if (uper_open_type_skip(opt_codec_ctx, pd)) - { - FREEMEM(epres); - _ASN_DECODE_STARVED; - } + case -1: + break; + case 0: + continue; + default: + if (uper_open_type_skip(opt_codec_ctx, pd)) + { + FREEMEM(epres); + _ASN_DECODE_STARVED; + } } break; } @@ -1411,7 +1411,7 @@ asn_dec_rval_t SEQUENCE_decode_uper(asn_codec_ctx_t *opt_codec_ctx, } static int SEQUENCE_handle_extensions(asn_TYPE_descriptor_t *td, void *sptr, - asn_per_outp_t *po1, asn_per_outp_t *po2) + asn_per_outp_t *po1, asn_per_outp_t *po2) { asn_SEQUENCE_specifics_t *specs = (asn_SEQUENCE_specifics_t *)td->specifics; int exts_present = 0; @@ -1431,7 +1431,7 @@ static int SEQUENCE_handle_extensions(asn_TYPE_descriptor_t *td, void *sptr, if (!IN_EXTENSION_GROUP(specs, edx)) { ASN_DEBUG("%s (@%d) is not extension", elm->type->name, - edx); + edx); continue; } @@ -1449,7 +1449,7 @@ static int SEQUENCE_handle_extensions(asn_TYPE_descriptor_t *td, void *sptr, } ASN_DEBUG("checking %s (@%d) present => %d", elm->type->name, edx, - present); + present); exts_count++; exts_present += present; @@ -1458,7 +1458,7 @@ static int SEQUENCE_handle_extensions(asn_TYPE_descriptor_t *td, void *sptr, /* Encode as open type field */ if (po2 && present && uper_open_type_put(elm->type, elm->per_constraints, *memb_ptr2, - po2)) + po2)) return -1; } @@ -1466,8 +1466,8 @@ static int SEQUENCE_handle_extensions(asn_TYPE_descriptor_t *td, void *sptr, } asn_enc_rval_t SEQUENCE_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *sptr, asn_per_outp_t *po) + asn_per_constraints_t *constraints, + void *sptr, asn_per_outp_t *po) { asn_SEQUENCE_specifics_t *specs = (asn_SEQUENCE_specifics_t *)td->specifics; asn_enc_rval_t er; @@ -1527,9 +1527,9 @@ asn_enc_rval_t SEQUENCE_encode_uper(asn_TYPE_descriptor_t *td, present = 0; ASN_DEBUG("Element %s %s %s->%s is %s", - elm->flags & ATF_POINTER ? "ptr" : "inline", - elm->default_value ? "def" : "wtv", td->name, elm->name, - present ? "present" : "absent"); + elm->flags & ATF_POINTER ? "ptr" : "inline", + elm->default_value ? "def" : "wtv", td->name, elm->name, + present ? "present" : "absent"); if (per_put_few_bits(po, present, 1)) _ASN_ENCODE_FAILED; } @@ -1537,7 +1537,7 @@ asn_enc_rval_t SEQUENCE_encode_uper(asn_TYPE_descriptor_t *td, * Encode the sequence ROOT elements. */ ASN_DEBUG("ext_after = %d, ec = %d, eb = %d", specs->ext_after, - td->elements_count, specs->ext_before); + td->elements_count, specs->ext_before); for (edx = 0; edx < ((specs->ext_after < 0) ? td->elements_count : specs->ext_before - 1); edx++) @@ -1557,7 +1557,7 @@ asn_enc_rval_t SEQUENCE_encode_uper(asn_TYPE_descriptor_t *td, if (!*memb_ptr2) { ASN_DEBUG("Element %s %d not present", elm->name, - edx); + edx); if (elm->optional) continue; /* Mandatory element is missing */ _ASN_ENCODE_FAILED; @@ -1575,7 +1575,7 @@ asn_enc_rval_t SEQUENCE_encode_uper(asn_TYPE_descriptor_t *td, ASN_DEBUG("Encoding %s->%s", td->name, elm->name); er = elm->type->uper_encoder(elm->type, elm->per_constraints, - *memb_ptr2, po); + *memb_ptr2, po); if (er.encoded == -1) return er; } diff --git a/src/core/libs/supl/asn-rrlp/constr_SEQUENCE_OF.c b/src/core/libs/supl/asn-rrlp/constr_SEQUENCE_OF.c index 00e6a2a4a..afdfa64a2 100644 --- a/src/core/libs/supl/asn-rrlp/constr_SEQUENCE_OF.c +++ b/src/core/libs/supl/asn-rrlp/constr_SEQUENCE_OF.c @@ -3,17 +3,17 @@ * All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ +#include #include #include -#include /* * The DER encoder of the SEQUENCE OF type. */ asn_enc_rval_t SEQUENCE_OF_encode_der(asn_TYPE_descriptor_t *td, void *ptr, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { asn_TYPE_member_t *elm = td->elements; asn_anonymous_sequence_ *list = _A_SEQUENCE_FROM_VOID(ptr); @@ -67,7 +67,7 @@ asn_enc_rval_t SEQUENCE_OF_encode_der(asn_TYPE_descriptor_t *td, void *ptr, void *memb_ptr = list->array[edx]; if (!memb_ptr) continue; erval = elm->type->der_encoder(elm->type, memb_ptr, 0, elm->tag, cb, - app_key); + app_key); if (erval.encoded == -1) return erval; encoding_size += erval.encoded; } @@ -92,10 +92,10 @@ asn_enc_rval_t SEQUENCE_OF_encode_der(asn_TYPE_descriptor_t *td, void *ptr, } asn_enc_rval_t SEQUENCE_OF_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, - int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { asn_enc_rval_t er; asn_SET_OF_specifics_t *specs = (asn_SET_OF_specifics_t *)td->specifics; @@ -125,7 +125,7 @@ asn_enc_rval_t SEQUENCE_OF_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, } tmper = elm->type->xer_encoder(elm->type, memb_ptr, ilevel + 1, - flags, cb, app_key); + flags, cb, app_key); if (tmper.encoded == -1) return tmper; if (tmper.encoded == 0 && specs->as_XMLValueList) { @@ -152,8 +152,8 @@ cb_failed: } asn_enc_rval_t SEQUENCE_OF_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *sptr, asn_per_outp_t *po) + asn_per_constraints_t *constraints, + void *sptr, asn_per_outp_t *po) { asn_anonymous_sequence_ *list; asn_per_constraint_t *ct; @@ -181,7 +181,7 @@ asn_enc_rval_t SEQUENCE_OF_encode_uper(asn_TYPE_descriptor_t *td, int not_in_root = (list->count < ct->lower_bound || list->count > ct->upper_bound); ASN_DEBUG("lb %ld ub %ld %s", ct->lower_bound, ct->upper_bound, - ct->flags & APC_EXTENSIBLE ? "ext" : "fix"); + ct->flags & APC_EXTENSIBLE ? "ext" : "fix"); if (ct->flags & APC_EXTENSIBLE) { /* Declare whether size is in extension root */ @@ -197,7 +197,7 @@ asn_enc_rval_t SEQUENCE_OF_encode_uper(asn_TYPE_descriptor_t *td, { /* X.691, #19.5: No length determinant */ if (per_put_few_bits(po, list->count - ct->lower_bound, - ct->effective_bits)) + ct->effective_bits)) _ASN_ENCODE_FAILED; } diff --git a/src/core/libs/supl/asn-rrlp/constr_SET_OF.c b/src/core/libs/supl/asn-rrlp/constr_SET_OF.c index 3b62e9e64..25638af5d 100644 --- a/src/core/libs/supl/asn-rrlp/constr_SET_OF.c +++ b/src/core/libs/supl/asn-rrlp/constr_SET_OF.c @@ -3,9 +3,9 @@ * All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ +#include #include #include -#include /* * Number of bytes left for this structure. @@ -79,8 +79,8 @@ * The decoder of the SET OF type. */ asn_dec_rval_t SET_OF_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **struct_ptr, - const void *ptr, size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, void **struct_ptr, + const void *ptr, size_t size, int tag_mode) { /* * Bring closer parts of structure description. @@ -123,191 +123,191 @@ asn_dec_rval_t SET_OF_decode_ber(asn_codec_ctx_t *opt_codec_ctx, */ switch (ctx->phase) { - case 0: - /* + case 0: + /* * PHASE 0. * Check that the set of tags associated with given structure * perfectly fits our expectations. */ - rval = ber_check_tags(opt_codec_ctx, td, ctx, ptr, size, - tag_mode, 1, &ctx->left, 0); - if (rval.code != RC_OK) - { - ASN_DEBUG("%s tagging check failed: %d", td->name, - rval.code); - return rval; - } + rval = ber_check_tags(opt_codec_ctx, td, ctx, ptr, size, + tag_mode, 1, &ctx->left, 0); + if (rval.code != RC_OK) + { + ASN_DEBUG("%s tagging check failed: %d", td->name, + rval.code); + return rval; + } - if (ctx->left >= 0) - ctx->left += rval.consumed; /* ?Subtracted below! */ - ADVANCE(rval.consumed); + if (ctx->left >= 0) + ctx->left += rval.consumed; /* ?Subtracted below! */ + ADVANCE(rval.consumed); - ASN_DEBUG( - "Structure consumes %ld bytes, " - "buffer %ld", - (long)ctx->left, (long)size); + ASN_DEBUG( + "Structure consumes %ld bytes, " + "buffer %ld", + (long)ctx->left, (long)size); - NEXT_PHASE(ctx); - /* Fall through */ - case 1: - /* + NEXT_PHASE(ctx); + /* Fall through */ + case 1: + /* * PHASE 1. * From the place where we've left it previously, * try to decode the next item. */ - for (;; ctx->step = 0) - { - ssize_t tag_len; /* Length of TLV's T */ + for (;; ctx->step = 0) + { + ssize_t tag_len; /* Length of TLV's T */ - if (ctx->step & 1) goto microphase2; + if (ctx->step & 1) goto microphase2; - /* + /* * MICROPHASE 1: Synchronize decoding. */ - if (ctx->left == 0) - { - ASN_DEBUG("End of SET OF %s", td->name); - /* + if (ctx->left == 0) + { + ASN_DEBUG("End of SET OF %s", td->name); + /* * No more things to decode. * Exit out of here. */ - PHASE_OUT(ctx); - RETURN(RC_OK); - } + PHASE_OUT(ctx); + RETURN(RC_OK); + } - /* + /* * Fetch the T from TLV. */ - tag_len = ber_fetch_tag(ptr, LEFT, &tlv_tag); - switch (tag_len) - { - case 0: - if (!SIZE_VIOLATION) RETURN(RC_WMORE); - /* Fall through */ - case -1: - RETURN(RC_FAIL); - } + tag_len = ber_fetch_tag(ptr, LEFT, &tlv_tag); + switch (tag_len) + { + case 0: + if (!SIZE_VIOLATION) RETURN(RC_WMORE); + /* Fall through */ + case -1: + RETURN(RC_FAIL); + } - if (ctx->left < 0 && ((const uint8_t *)ptr)[0] == 0) - { - if (LEFT < 2) - { - if (SIZE_VIOLATION) - RETURN(RC_FAIL); - else - RETURN(RC_WMORE); - } - else if (((const uint8_t *)ptr)[1] == 0) - { - /* + if (ctx->left < 0 && ((const uint8_t *)ptr)[0] == 0) + { + if (LEFT < 2) + { + if (SIZE_VIOLATION) + RETURN(RC_FAIL); + else + RETURN(RC_WMORE); + } + else if (((const uint8_t *)ptr)[1] == 0) + { + /* * Found the terminator of the * indefinite length structure. */ - break; - } - } + break; + } + } - /* Outmost tag may be unknown and cannot be + /* Outmost tag may be unknown and cannot be * fetched/compared */ - if (elm->tag != (ber_tlv_tag_t)-1) - { - if (BER_TAGS_EQUAL(tlv_tag, elm->tag)) - { - /* + if (elm->tag != (ber_tlv_tag_t)-1) + { + if (BER_TAGS_EQUAL(tlv_tag, elm->tag)) + { + /* * The new list member of expected type * has arrived. */ - } - else - { - ASN_DEBUG( - "Unexpected tag %s fixed SET OF %s", - ber_tlv_tag_string(tlv_tag), - td->name); - ASN_DEBUG("%s SET OF has tag %s", - td->name, - ber_tlv_tag_string(elm->tag)); - RETURN(RC_FAIL); - } - } + } + else + { + ASN_DEBUG( + "Unexpected tag %s fixed SET OF %s", + ber_tlv_tag_string(tlv_tag), + td->name); + ASN_DEBUG("%s SET OF has tag %s", + td->name, + ber_tlv_tag_string(elm->tag)); + RETURN(RC_FAIL); + } + } - /* + /* * MICROPHASE 2: Invoke the member-specific decoder. */ - ctx->step |= 1; /* Confirm entering next microphase */ - microphase2: + ctx->step |= 1; /* Confirm entering next microphase */ + microphase2: - /* + /* * Invoke the member fetch routine according to member's * type */ - rval = elm->type->ber_decoder(opt_codec_ctx, elm->type, - &ctx->ptr, ptr, LEFT, 0); - ASN_DEBUG("In %s SET OF %s code %d consumed %d", - td->name, elm->type->name, rval.code, - (int)rval.consumed); - switch (rval.code) + rval = elm->type->ber_decoder(opt_codec_ctx, elm->type, + &ctx->ptr, ptr, LEFT, 0); + ASN_DEBUG("In %s SET OF %s code %d consumed %d", + td->name, elm->type->name, rval.code, + (int)rval.consumed); + switch (rval.code) + { + case RC_OK: { - case RC_OK: - { - asn_anonymous_set_ *list = - _A_SET_FROM_VOID(st); - if (ASN_SET_ADD(list, ctx->ptr) != 0) - RETURN(RC_FAIL); - else - ctx->ptr = 0; - } - break; - case RC_WMORE: /* More data expected */ - if (!SIZE_VIOLATION) - { - ADVANCE(rval.consumed); - RETURN(RC_WMORE); - } - /* Fall through */ - case RC_FAIL: /* Fatal error */ - ASN_STRUCT_FREE(*elm->type, ctx->ptr); - ctx->ptr = 0; + asn_anonymous_set_ *list = + _A_SET_FROM_VOID(st); + if (ASN_SET_ADD(list, ctx->ptr) != 0) RETURN(RC_FAIL); - } /* switch(rval) */ + else + ctx->ptr = 0; + } + break; + case RC_WMORE: /* More data expected */ + if (!SIZE_VIOLATION) + { + ADVANCE(rval.consumed); + RETURN(RC_WMORE); + } + /* Fall through */ + case RC_FAIL: /* Fatal error */ + ASN_STRUCT_FREE(*elm->type, ctx->ptr); + ctx->ptr = 0; + RETURN(RC_FAIL); + } /* switch(rval) */ - ADVANCE(rval.consumed); - } /* for(all list members) */ + ADVANCE(rval.consumed); + } /* for(all list members) */ - NEXT_PHASE(ctx); - case 2: - /* + NEXT_PHASE(ctx); + case 2: + /* * Read in all "end of content" TLVs. */ - while (ctx->left < 0) - { - if (LEFT < 2) - { - if (LEFT > 0 && ((const char *)ptr)[0] != 0) - { - /* Unexpected tag */ - RETURN(RC_FAIL); - } - else - { - RETURN(RC_WMORE); - } - } - if (((const char *)ptr)[0] == 0 && - ((const char *)ptr)[1] == 0) - { - ADVANCE(2); - ctx->left++; - } - else - { - RETURN(RC_FAIL); - } - } + while (ctx->left < 0) + { + if (LEFT < 2) + { + if (LEFT > 0 && ((const char *)ptr)[0] != 0) + { + /* Unexpected tag */ + RETURN(RC_FAIL); + } + else + { + RETURN(RC_WMORE); + } + } + if (((const char *)ptr)[0] == 0 && + ((const char *)ptr)[1] == 0) + { + ADVANCE(2); + ctx->left++; + } + else + { + RETURN(RC_FAIL); + } + } - PHASE_OUT(ctx); + PHASE_OUT(ctx); } RETURN(RC_OK); @@ -362,8 +362,8 @@ static int _el_buf_cmp(const void *ap, const void *bp) * The DER encoder of the SET OF type. */ asn_enc_rval_t SET_OF_encode_der(asn_TYPE_descriptor_t *td, void *ptr, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { asn_TYPE_member_t *elm = td->elements; asn_TYPE_descriptor_t *elm_type = elm->type; @@ -466,7 +466,7 @@ asn_enc_rval_t SET_OF_encode_der(asn_TYPE_descriptor_t *td, void *ptr, * Encode the member into the prepared space. */ erval = der_encoder(elm_type, memb_ptr, 0, elm->tag, _el_addbytes, - encoded_el); + encoded_el); if (erval.encoded == -1) { for (; edx >= 0; edx--) FREEMEM(encoded_els[edx].buf); @@ -531,9 +531,9 @@ asn_enc_rval_t SET_OF_encode_der(asn_TYPE_descriptor_t *td, void *ptr, * Decode the XER (XML) data. */ asn_dec_rval_t SET_OF_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **struct_ptr, - const char *opt_mname, const void *buf_ptr, - size_t size) + asn_TYPE_descriptor_t *td, void **struct_ptr, + const char *opt_mname, const void *buf_ptr, + size_t size) { /* * Bring closer parts of structure description. @@ -624,63 +624,63 @@ asn_dec_rval_t SET_OF_decode_xer(asn_codec_ctx_t *opt_codec_ctx, ch_size = xer_next_token(&ctx->context, buf_ptr, size, &ch_type); switch (ch_size) { - case -1: - RETURN(RC_FAIL); - case 0: - RETURN(RC_WMORE); - default: - switch (ch_type) - { - case PXER_COMMENT: /* Got XML comment */ - case PXER_TEXT: /* Ignore free-standing text */ - XER_ADVANCE(ch_size); /* Skip silently */ - continue; - case PXER_TAG: - break; /* Check the rest down there */ - } + case -1: + RETURN(RC_FAIL); + case 0: + RETURN(RC_WMORE); + default: + switch (ch_type) + { + case PXER_COMMENT: /* Got XML comment */ + case PXER_TEXT: /* Ignore free-standing text */ + XER_ADVANCE(ch_size); /* Skip silently */ + continue; + case PXER_TAG: + break; /* Check the rest down there */ + } } tcv = xer_check_tag(buf_ptr, ch_size, xml_tag); ASN_DEBUG("XER/SET OF: tcv = %d, ph=%d t=%s", tcv, ctx->phase, - xml_tag); + xml_tag); switch (tcv) { - case XCT_CLOSING: - if (ctx->phase == 0) break; - ctx->phase = 0; - /* Fall through */ - case XCT_BOTH: - if (ctx->phase == 0) - { - /* No more things to decode */ - XER_ADVANCE(ch_size); - ctx->phase = 3; /* Phase out */ - RETURN(RC_OK); - } - /* Fall through */ - case XCT_OPENING: - if (ctx->phase == 0) - { - XER_ADVANCE(ch_size); - ctx->phase = 1; /* Processing body phase */ - continue; - } - /* Fall through */ - case XCT_UNKNOWN_OP: - case XCT_UNKNOWN_BO: + case XCT_CLOSING: + if (ctx->phase == 0) break; + ctx->phase = 0; + /* Fall through */ + case XCT_BOTH: + if (ctx->phase == 0) + { + /* No more things to decode */ + XER_ADVANCE(ch_size); + ctx->phase = 3; /* Phase out */ + RETURN(RC_OK); + } + /* Fall through */ + case XCT_OPENING: + if (ctx->phase == 0) + { + XER_ADVANCE(ch_size); + ctx->phase = 1; /* Processing body phase */ + continue; + } + /* Fall through */ + case XCT_UNKNOWN_OP: + case XCT_UNKNOWN_BO: - ASN_DEBUG("XER/SET OF: tcv=%d, ph=%d", tcv, ctx->phase); - if (ctx->phase == 1) - { - /* + ASN_DEBUG("XER/SET OF: tcv=%d, ph=%d", tcv, ctx->phase); + if (ctx->phase == 1) + { + /* * Process a single possible member. */ - ctx->phase = 2; - continue; - } - /* Fall through */ - default: - break; + ctx->phase = 2; + continue; + } + /* Fall through */ + default: + break; } ASN_DEBUG("Unexpected XML tag in SET OF"); @@ -698,7 +698,7 @@ typedef struct xer_tmp_enc_s size_t size; } xer_tmp_enc_t; static int SET_OF_encode_xer_callback(const void *buffer, size_t size, - void *key) + void *key) { xer_tmp_enc_t *t = (xer_tmp_enc_t *)key; if (t->offset + size >= t->size) @@ -729,8 +729,8 @@ static int SET_OF_xer_order(const void *aptr, const void *bptr) } asn_enc_rval_t SET_OF_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { asn_enc_rval_t er; asn_SET_OF_specifics_t *specs = (asn_SET_OF_specifics_t *)td->specifics; @@ -846,7 +846,7 @@ cleanup: } int SET_OF_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { asn_TYPE_member_t *elm = td->elements; const asn_anonymous_set_ *list = _A_CSET_FROM_VOID(sptr); @@ -868,7 +868,7 @@ int SET_OF_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, _i_INDENT(1); ret = elm->type->print_struct(elm->type, memb_ptr, ilevel + 1, cb, - app_key); + app_key); if (ret) return ret; } @@ -917,7 +917,7 @@ void SET_OF_free(asn_TYPE_descriptor_t *td, void *ptr, int contents_only) } int SET_OF_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { asn_TYPE_member_t *elm = td->elements; asn_constr_check_f *constr; @@ -927,7 +927,7 @@ int SET_OF_constraint(asn_TYPE_descriptor_t *td, const void *sptr, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -960,9 +960,9 @@ int SET_OF_constraint(asn_TYPE_descriptor_t *td, const void *sptr, } asn_dec_rval_t SET_OF_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd) { asn_dec_rval_t rv; asn_SET_OF_specifics_t *specs = (asn_SET_OF_specifics_t *)td->specifics; @@ -1005,7 +1005,7 @@ asn_dec_rval_t SET_OF_decode_uper(asn_codec_ctx_t *opt_codec_ctx, /* X.691, #19.5: No length determinant */ nelems = per_get_few_bits(pd, ct->effective_bits); ASN_DEBUG("Preparing to fetch %ld+%ld elements from %s", - (long)nelems, ct->lower_bound, td->name); + (long)nelems, ct->lower_bound, td->name); if (nelems < 0) _ASN_DECODE_STARVED; nelems += ct->lower_bound; } @@ -1019,9 +1019,9 @@ asn_dec_rval_t SET_OF_decode_uper(asn_codec_ctx_t *opt_codec_ctx, if (nelems < 0) { nelems = uper_get_length(pd, ct ? ct->effective_bits : -1, - &repeat); + &repeat); ASN_DEBUG("Got to decode %d elements (eff %d)", (int)nelems, - (long)ct ? ct->effective_bits : -1); + (long)ct ? ct->effective_bits : -1); if (nelems < 0) _ASN_DECODE_STARVED; } @@ -1031,21 +1031,21 @@ asn_dec_rval_t SET_OF_decode_uper(asn_codec_ctx_t *opt_codec_ctx, ASN_DEBUG("SET OF %s decoding", elm->type->name); rv = elm->type->uper_decoder(opt_codec_ctx, elm->type, - elm->per_constraints, &ptr, pd); + elm->per_constraints, &ptr, pd); ASN_DEBUG("%s SET OF %s decoded %d, %p", td->name, - elm->type->name, rv.code, ptr); + elm->type->name, rv.code, ptr); if (rv.code == RC_OK) { if (ASN_SET_ADD(list, ptr) == 0) continue; ASN_DEBUG("Failed to add element into %s", - td->name); + td->name); /* Fall through */ rv.code = RC_FAIL; } else { ASN_DEBUG("Failed decoding %s of %s (SET OF)", - elm->type->name, td->name); + elm->type->name, td->name); } if (ptr) ASN_STRUCT_FREE(*elm->type, ptr); return rv; diff --git a/src/core/libs/supl/asn-rrlp/constr_TYPE.c b/src/core/libs/supl/asn-rrlp/constr_TYPE.c index 05c70989d..0e0cf4bda 100644 --- a/src/core/libs/supl/asn-rrlp/constr_TYPE.c +++ b/src/core/libs/supl/asn-rrlp/constr_TYPE.c @@ -17,8 +17,8 @@ static asn_app_consume_bytes_f _print2fp; * Return the outmost tag of the type. */ ber_tlv_tag_t asn_TYPE_outmost_tag(asn_TYPE_descriptor_t *type_descriptor, - const void *struct_ptr, int tag_mode, - ber_tlv_tag_t tag) + const void *struct_ptr, int tag_mode, + ber_tlv_tag_t tag) { if (tag_mode) return tag; diff --git a/src/core/libs/supl/asn-rrlp/constr_TYPE.h b/src/core/libs/supl/asn-rrlp/constr_TYPE.h index 3af569530..92b9fd914 100644 --- a/src/core/libs/supl/asn-rrlp/constr_TYPE.h +++ b/src/core/libs/supl/asn-rrlp/constr_TYPE.h @@ -39,12 +39,12 @@ extern "C" } asn_struct_ctx_t; #include /* Basic Encoding Rules decoder */ +#include /* Subtype constraints support */ #include /* Distinguished Encoding Rules encoder */ -#include /* Decoder of XER (XML, text) */ -#include /* Encoder into XER (XML, text) */ #include /* Packet Encoding Rules decoder */ #include /* Packet Encoding Rules encoder */ -#include /* Subtype constraints support */ +#include /* Decoder of XER (XML, text) */ +#include /* Encoder into XER (XML, text) */ /* * Free the structure according to its specification. @@ -110,10 +110,10 @@ extern "C" * Tags that are expected to occur. */ asn_outmost_tag_f *outmost_tag; /* */ - ber_tlv_tag_t *tags; /* Effective tags sequence for this type */ - int tags_count; /* Number of tags which are expected */ - ber_tlv_tag_t *all_tags; /* Every tag for BER/containment */ - int all_tags_count; /* Number of tags */ + ber_tlv_tag_t *tags; /* Effective tags sequence for this type */ + int tags_count; /* Number of tags which are expected */ + ber_tlv_tag_t *all_tags; /* Every tag for BER/containment */ + int all_tags_count; /* Number of tags */ asn_per_constraints_t *per_constraints; /* PER compiled constraints */ @@ -142,16 +142,16 @@ extern "C" }; typedef struct asn_TYPE_member_s { - enum asn_TYPE_flags_e flags; /* Element's presentation flags */ - int optional; /* Following optional members, including current */ - int memb_offset; /* Offset of the element */ - ber_tlv_tag_t tag; /* Outmost (most immediate) tag */ - int tag_mode; /* IMPLICIT/no/EXPLICIT tag at current level */ - asn_TYPE_descriptor_t *type; /* Member type descriptor */ - asn_constr_check_f *memb_constraints; /* Constraints validator */ - asn_per_constraints_t *per_constraints; /* PER compiled constraints */ + enum asn_TYPE_flags_e flags; /* Element's presentation flags */ + int optional; /* Following optional members, including current */ + int memb_offset; /* Offset of the element */ + ber_tlv_tag_t tag; /* Outmost (most immediate) tag */ + int tag_mode; /* IMPLICIT/no/EXPLICIT tag at current level */ + asn_TYPE_descriptor_t *type; /* Member type descriptor */ + asn_constr_check_f *memb_constraints; /* Constraints validator */ + asn_per_constraints_t *per_constraints; /* PER compiled constraints */ int (*default_value)(int setval, void **sptr); /* DEFAULT */ - char *name; /* ASN.1 identifier of the element */ + char *name; /* ASN.1 identifier of the element */ } asn_TYPE_member_t; /* @@ -174,9 +174,9 @@ extern "C" * -1: Problem dumping the structure. * (See also xer_fprint() in xer_encoder.h) */ - int asn_fprint(FILE *stream, /* Destination stream descriptor */ - asn_TYPE_descriptor_t *td, /* ASN.1 type descriptor */ - const void *struct_ptr); /* Structure to be printed */ + int asn_fprint(FILE *stream, /* Destination stream descriptor */ + asn_TYPE_descriptor_t *td, /* ASN.1 type descriptor */ + const void *struct_ptr); /* Structure to be printed */ #ifdef __cplusplus } diff --git a/src/core/libs/supl/asn-rrlp/constraints.c b/src/core/libs/supl/asn-rrlp/constraints.c index ba03304f1..3d96897ac 100644 --- a/src/core/libs/supl/asn-rrlp/constraints.c +++ b/src/core/libs/supl/asn-rrlp/constraints.c @@ -1,9 +1,11 @@ +// clang-format off #include "asn_internal.h" #include "constraints.h" +// clang-format on int asn_generic_no_constraint(asn_TYPE_descriptor_t *type_descriptor, - const void *struct_ptr, - asn_app_constraint_failed_f *cb, void *key) + const void *struct_ptr, + asn_app_constraint_failed_f *cb, void *key) { (void)type_descriptor; /* Unused argument */ (void)struct_ptr; /* Unused argument */ @@ -15,8 +17,8 @@ int asn_generic_no_constraint(asn_TYPE_descriptor_t *type_descriptor, } int asn_generic_unknown_constraint(asn_TYPE_descriptor_t *type_descriptor, - const void *struct_ptr, - asn_app_constraint_failed_f *cb, void *key) + const void *struct_ptr, + asn_app_constraint_failed_f *cb, void *key) { (void)type_descriptor; /* Unused argument */ (void)struct_ptr; /* Unused argument */ @@ -36,7 +38,7 @@ struct errbufDesc }; static void _asn_i_ctfailcb(void *key, asn_TYPE_descriptor_t *td, - const void *sptr, const char *fmt, ...) + const void *sptr, const char *fmt, ...) { struct errbufDesc *arg = key; va_list ap; @@ -77,7 +79,7 @@ static void _asn_i_ctfailcb(void *key, asn_TYPE_descriptor_t *td, } int asn_check_constraints(asn_TYPE_descriptor_t *type_descriptor, - const void *struct_ptr, char *errbuf, size_t *errlen) + const void *struct_ptr, char *errbuf, size_t *errlen) { struct errbufDesc arg; int ret; @@ -88,7 +90,7 @@ int asn_check_constraints(asn_TYPE_descriptor_t *type_descriptor, arg.errlen = errlen ? *errlen : 0; ret = type_descriptor->check_constraints(type_descriptor, struct_ptr, - _asn_i_ctfailcb, &arg); + _asn_i_ctfailcb, &arg); if (ret == -1 && errlen) *errlen = arg.errlen; return ret; diff --git a/src/core/libs/supl/asn-rrlp/constraints.h b/src/core/libs/supl/asn-rrlp/constraints.h index 5d339e2ff..ec9e669c0 100644 --- a/src/core/libs/supl/asn-rrlp/constraints.h +++ b/src/core/libs/supl/asn-rrlp/constraints.h @@ -40,14 +40,14 @@ extern "C" typedef int(asn_constr_check_f)( struct asn_TYPE_descriptor_s *type_descriptor, const void *struct_ptr, asn_app_constraint_failed_f *optional_callback, /* Log the error */ - void *optional_app_key /* Opaque key passed to a callback */ + void *optional_app_key /* Opaque key passed to a callback */ ); /******************************* * INTERNALLY USEFUL FUNCTIONS * *******************************/ - asn_constr_check_f asn_generic_no_constraint; /* No constraint whatsoever */ + asn_constr_check_f asn_generic_no_constraint; /* No constraint whatsoever */ asn_constr_check_f asn_generic_unknown_constraint; /* Not fully supported */ /* diff --git a/src/core/libs/supl/asn-rrlp/converter-sample.c b/src/core/libs/supl/asn-rrlp/converter-sample.c index 90b889405..7433cb18c 100644 --- a/src/core/libs/supl/asn-rrlp/converter-sample.c +++ b/src/core/libs/supl/asn-rrlp/converter-sample.c @@ -10,16 +10,15 @@ #ifdef HAVE_CONFIG_H #include #endif -#include -#include -#include /* for atoi(3) */ -#include /* for getopt(3) */ -#include /* for strerror(3) */ -#include /* for EX_* exit codes */ -#include /* for errno */ - #include #include /* for _ASN_DEFAULT_STACK_MAX */ +#include /* for errno */ +#include +#include /* for atoi(3) */ +#include /* for strerror(3) */ +#include +#include /* for EX_* exit codes */ +#include /* for getopt(3) */ /* Convert "Type" defined by -DPDU into "asn_DEF_Type" */ #define ASN_DEF_PDU(t) asn_DEF_##t @@ -35,8 +34,8 @@ extern asn_TYPE_descriptor_t *asn_pdu_collection[]; * Open file and parse its contents. */ static void *data_decode_from_file(asn_TYPE_descriptor_t *pduType, FILE *file, - const char *name, ssize_t suggested_bufsize, - int first_pdu); + const char *name, ssize_t suggested_bufsize, + int first_pdu); static int write_out(const void *buffer, size_t size, void *key); static FILE *argument_to_file(char *av[], int idx); static char *argument_to_name(char *av[], int idx); @@ -100,202 +99,202 @@ int main(int ac, char *av[]) */ while ((ch = getopt(ac, av, "i:o:1b:cdn:p:hs:" JUNKOPT)) != -1) switch (ch) { - case 'i': - if (optarg[0] == 'b') - { - iform = INP_BER; - break; - } - if (optarg[0] == 'x') - { - iform = INP_XER; - break; - } - if (pduType->uper_decoder && optarg[0] == 'p') - { - iform = INP_PER; - break; - } - fprintf(stderr, - "-i: '%s': improper format selector\n", + case 'i': + if (optarg[0] == 'b') + { + iform = INP_BER; + break; + } + if (optarg[0] == 'x') + { + iform = INP_XER; + break; + } + if (pduType->uper_decoder && optarg[0] == 'p') + { + iform = INP_PER; + break; + } + fprintf(stderr, + "-i: '%s': improper format selector\n", + optarg); + exit(EX_UNAVAILABLE); + case 'o': + if (optarg[0] == 'd') + { + oform = OUT_DER; + break; + } + if (pduType->uper_encoder && optarg[0] == 'p') + { + oform = OUT_PER; + break; + } + if (optarg[0] == 'x') + { + oform = OUT_XER; + break; + } + if (optarg[0] == 't') + { + oform = OUT_TEXT; + break; + } + if (optarg[0] == 'n') + { + oform = OUT_NULL; + break; + } + fprintf(stderr, + "-o: '%s': improper format selector\n", + optarg); + exit(EX_UNAVAILABLE); + case '1': + opt_onepdu = 1; + break; + case 'b': + suggested_bufsize = atoi(optarg); + if (suggested_bufsize < 1 || + suggested_bufsize > 16 * 1024 * 1024) + { + fprintf(stderr, + "-b %s: Improper buffer size (1..16M)\n", optarg); - exit(EX_UNAVAILABLE); - case 'o': - if (optarg[0] == 'd') - { - oform = OUT_DER; - break; - } - if (pduType->uper_encoder && optarg[0] == 'p') - { - oform = OUT_PER; - break; - } - if (optarg[0] == 'x') - { - oform = OUT_XER; - break; - } - if (optarg[0] == 't') - { - oform = OUT_TEXT; - break; - } - if (optarg[0] == 'n') - { - oform = OUT_NULL; - break; - } - fprintf(stderr, - "-o: '%s': improper format selector\n", + exit(EX_UNAVAILABLE); + } + break; + case 'c': + opt_check = 1; + break; + case 'd': + opt_debug++; /* Double -dd means ASN.1 debug */ + break; + case 'n': + number_of_iterations = atoi(optarg); + if (number_of_iterations < 1) + { + fprintf(stderr, + "-n %s: Improper iterations count\n", optarg); - exit(EX_UNAVAILABLE); - case '1': - opt_onepdu = 1; - break; - case 'b': - suggested_bufsize = atoi(optarg); - if (suggested_bufsize < 1 || - suggested_bufsize > 16 * 1024 * 1024) - { - fprintf(stderr, - "-b %s: Improper buffer size (1..16M)\n", - optarg); - exit(EX_UNAVAILABLE); - } - break; - case 'c': - opt_check = 1; - break; - case 'd': - opt_debug++; /* Double -dd means ASN.1 debug */ - break; - case 'n': - number_of_iterations = atoi(optarg); - if (number_of_iterations < 1) - { - fprintf(stderr, - "-n %s: Improper iterations count\n", - optarg); - exit(EX_UNAVAILABLE); - } - break; - case 'p': - if (strcmp(optarg, "er-nopad") == 0) - { - opt_nopad = 1; - break; - } + exit(EX_UNAVAILABLE); + } + break; + case 'p': + if (strcmp(optarg, "er-nopad") == 0) + { + opt_nopad = 1; + break; + } #ifdef ASN_PDU_COLLECTION - if (strcmp(optarg, "list") == 0) - { - asn_TYPE_descriptor_t **pdu = asn_pdu_collection; - fprintf(stderr, "Available PDU types:\n"); - for (; *pdu; pdu++) printf("%s\n", (*pdu)->name); - exit(0); - } - else if (optarg[0] >= 'A' && optarg[0] <= 'Z') - { - asn_TYPE_descriptor_t **pdu = asn_pdu_collection; - while (*pdu && strcmp((*pdu)->name, optarg)) pdu++; - if (*pdu) - { - pduType = *pdu; - break; - } - fprintf(stderr, "-p %s: Unrecognized PDU\n", - optarg); - } + if (strcmp(optarg, "list") == 0) + { + asn_TYPE_descriptor_t **pdu = asn_pdu_collection; + fprintf(stderr, "Available PDU types:\n"); + for (; *pdu; pdu++) printf("%s\n", (*pdu)->name); + exit(0); + } + else if (optarg[0] >= 'A' && optarg[0] <= 'Z') + { + asn_TYPE_descriptor_t **pdu = asn_pdu_collection; + while (*pdu && strcmp((*pdu)->name, optarg)) pdu++; + if (*pdu) + { + pduType = *pdu; + break; + } + fprintf(stderr, "-p %s: Unrecognized PDU\n", + optarg); + } #endif /* ASN_PDU_COLLECTION */ - fprintf(stderr, "-p %s: Unrecognized option\n", optarg); - exit(EX_UNAVAILABLE); - case 's': - opt_stack = atoi(optarg); - if (opt_stack < 0) - { - fprintf(stderr, - "-s %s: Non-negative value expected\n", - optarg); - exit(EX_UNAVAILABLE); - } - break; + fprintf(stderr, "-p %s: Unrecognized option\n", optarg); + exit(EX_UNAVAILABLE); + case 's': + opt_stack = atoi(optarg); + if (opt_stack < 0) + { + fprintf(stderr, + "-s %s: Non-negative value expected\n", + optarg); + exit(EX_UNAVAILABLE); + } + break; #ifdef JUNKTEST - case 'J': - opt_jprob = strtod(optarg, 0); - if (opt_jprob <= 0.0 || opt_jprob > 1.0) - { - fprintf(stderr, - "-J %s: Probability range 0..1 expected \n", - optarg); - exit(EX_UNAVAILABLE); - } - break; + case 'J': + opt_jprob = strtod(optarg, 0); + if (opt_jprob <= 0.0 || opt_jprob > 1.0) + { + fprintf(stderr, + "-J %s: Probability range 0..1 expected \n", + optarg); + exit(EX_UNAVAILABLE); + } + break; #endif /* JUNKTEST */ - case 'h': - default: + case 'h': + default: #ifdef ASN_CONVERTER_TITLE #define _AXS(x) #x #define _ASX(x) _AXS(x) - fprintf(stderr, "%s\n", _ASX(ASN_CONVERTER_TITLE)); + fprintf(stderr, "%s\n", _ASX(ASN_CONVERTER_TITLE)); #endif - fprintf(stderr, "Usage: %s [options] ...\n", - av[0]); - fprintf(stderr, "Where options are:\n"); - if (pduType->uper_decoder) - fprintf( - stderr, - " -iper Input is in Unaligned PER (Packed " - "Encoding Rules) (DEFAULT)\n"); - fprintf(stderr, - " -iber Input is in BER (Basic Encoding " - "Rules)%s\n", - iform == INP_PER ? "" : " (DEFAULT)"); - fprintf(stderr, - " -ixer Input is in XER (XML Encoding " - "Rules)\n"); - if (pduType->uper_encoder) - fprintf( - stderr, - " -oper Output in Unaligned PER (Packed " - "Encoding " - "Rules)\n"); + fprintf(stderr, "Usage: %s [options] ...\n", + av[0]); + fprintf(stderr, "Where options are:\n"); + if (pduType->uper_decoder) fprintf( stderr, - " -oder Output in DER (Distinguished Encoding " - "Rules)\n" - " -oxer Output in XER (XML Encoding Rules) " - "(DEFAULT)\n" - " -otext Output in plain semi-structured text " - "(dump)\n" - " -onull Verify (decode) input, but do not " - "output\n"); - if (pduType->uper_decoder) - fprintf(stderr, - " -per-nopad Assume PER PDUs are not padded " - "(-iper)\n"); + " -iper Input is in Unaligned PER (Packed " + "Encoding Rules) (DEFAULT)\n"); + fprintf(stderr, + " -iber Input is in BER (Basic Encoding " + "Rules)%s\n", + iform == INP_PER ? "" : " (DEFAULT)"); + fprintf(stderr, + " -ixer Input is in XER (XML Encoding " + "Rules)\n"); + if (pduType->uper_encoder) + fprintf( + stderr, + " -oper Output in Unaligned PER (Packed " + "Encoding " + "Rules)\n"); + fprintf( + stderr, + " -oder Output in DER (Distinguished Encoding " + "Rules)\n" + " -oxer Output in XER (XML Encoding Rules) " + "(DEFAULT)\n" + " -otext Output in plain semi-structured text " + "(dump)\n" + " -onull Verify (decode) input, but do not " + "output\n"); + if (pduType->uper_decoder) + fprintf(stderr, + " -per-nopad Assume PER PDUs are not padded " + "(-iper)\n"); #ifdef ASN_PDU_COLLECTION - fprintf(stderr, - " -p Specify PDU type to decode\n" - " -p list List available PDUs\n"); + fprintf(stderr, + " -p Specify PDU type to decode\n" + " -p list List available PDUs\n"); #endif /* ASN_PDU_COLLECTION */ - fprintf( - stderr, - " -1 Decode only the first PDU in file\n" - " -b Set the i/o buffer size (default is " - "%ld)\n" - " -c Check ASN.1 constraints after " - "decoding\n" - " -d Enable debugging (-dd is even better)\n" - " -n Process files times\n" - " -s Set the stack usage limit (default is " - "%d)\n" + fprintf( + stderr, + " -1 Decode only the first PDU in file\n" + " -b Set the i/o buffer size (default is " + "%ld)\n" + " -c Check ASN.1 constraints after " + "decoding\n" + " -d Enable debugging (-dd is even better)\n" + " -n Process files times\n" + " -s Set the stack usage limit (default is " + "%d)\n" #ifdef JUNKTEST - " -J Set random junk test bit garbaging " - "probability\n" + " -J Set random junk test bit garbaging " + "probability\n" #endif - , - (long)suggested_bufsize, _ASN_DEFAULT_STACK_MAX); - exit(EX_USAGE); + , + (long)suggested_bufsize, _ASN_DEFAULT_STACK_MAX); + exit(EX_USAGE); } ac -= optind; @@ -304,9 +303,9 @@ int main(int ac, char *av[]) if (ac < 1) { fprintf(stderr, - "%s: No input files specified. " - "Try '-h' for more information\n", - av[-optind]); + "%s: No input files specified. " + "Try '-h' for more information\n", + av[-optind]); exit(EX_USAGE); } @@ -355,70 +354,70 @@ int main(int ac, char *av[]) char errbuf[128]; size_t errlen = sizeof(errbuf); if (asn_check_constraints(pduType, - structure, errbuf, - &errlen)) + structure, errbuf, + &errlen)) { fprintf(stderr, - "%s: ASN.1 constraint " - "check failed: %s\n", - name, errbuf); + "%s: ASN.1 constraint " + "check failed: %s\n", + name, errbuf); exit(EX_DATAERR); } } switch (oform) { - case OUT_NULL: + case OUT_NULL: #ifdef JUNKTEST - if (opt_jprob == 0.0) + if (opt_jprob == 0.0) #endif - fprintf( - stderr, - "%s: decoded successfully\n", - name); - break; - case OUT_TEXT: /* -otext */ - asn_fprint(stdout, pduType, structure); - break; - case OUT_XER: /* -oxer */ - if (xer_fprint(stdout, pduType, - structure)) - { - fprintf(stderr, - "%s: Cannot convert %s " - "into XML\n", - name, pduType->name); - exit(EX_UNAVAILABLE); - } - break; - case OUT_DER: - erv = der_encode(pduType, structure, - write_out, stdout); - if (erv.encoded < 0) - { - fprintf(stderr, - "%s: Cannot convert %s " - "into DER\n", - name, pduType->name); - exit(EX_UNAVAILABLE); - } - DEBUG("Encoded in %ld bytes of DER", - (long)erv.encoded); - break; - case OUT_PER: - erv = uper_encode(pduType, structure, - write_out, stdout); - if (erv.encoded < 0) - { - fprintf(stderr, - "%s: Cannot convert %s " - "into Unaligned PER\n", - name, pduType->name); - exit(EX_UNAVAILABLE); - } - DEBUG("Encoded in %ld bits of UPER", - (long)erv.encoded); - break; + fprintf( + stderr, + "%s: decoded successfully\n", + name); + break; + case OUT_TEXT: /* -otext */ + asn_fprint(stdout, pduType, structure); + break; + case OUT_XER: /* -oxer */ + if (xer_fprint(stdout, pduType, + structure)) + { + fprintf(stderr, + "%s: Cannot convert %s " + "into XML\n", + name, pduType->name); + exit(EX_UNAVAILABLE); + } + break; + case OUT_DER: + erv = der_encode(pduType, structure, + write_out, stdout); + if (erv.encoded < 0) + { + fprintf(stderr, + "%s: Cannot convert %s " + "into DER\n", + name, pduType->name); + exit(EX_UNAVAILABLE); + } + DEBUG("Encoded in %ld bytes of DER", + (long)erv.encoded); + break; + case OUT_PER: + erv = uper_encode(pduType, structure, + write_out, stdout); + if (erv.encoded < 0) + { + fprintf(stderr, + "%s: Cannot convert %s " + "into Unaligned PER\n", + name, pduType->name); + exit(EX_UNAVAILABLE); + } + DEBUG("Encoded in %ld bits of UPER", + (long)erv.encoded); + break; } ASN_STRUCT_FREE(*pduType, structure); @@ -432,7 +431,7 @@ int main(int ac, char *av[]) if (opt_jprob > 0.0) { fprintf(stderr, "Junked %f OK (%d/%d)\n", opt_jprob, junk_failures, - number_of_iterations); + number_of_iterations); } #endif /* JUNKTEST */ @@ -456,16 +455,16 @@ static void buffer_dump() uint8_t *e = p + DynamicBuffer.length - (DynamicBuffer.unbits ? 1 : 0); if (!opt_debug) return; DEBUG("Buffer: { d=%p, o=%ld, l=%ld, u=%ld, a=%ld, s=%ld }", - DynamicBuffer.data, (long)DynamicBuffer.offset, - (long)DynamicBuffer.length, (long)DynamicBuffer.unbits, - (long)DynamicBuffer.allocated, (long)DynamicBuffer.bytes_shifted); + DynamicBuffer.data, (long)DynamicBuffer.offset, + (long)DynamicBuffer.length, (long)DynamicBuffer.unbits, + (long)DynamicBuffer.allocated, (long)DynamicBuffer.bytes_shifted); for (; p < e; p++) { fprintf(stderr, " %c%c%c%c%c%c%c%c", ((*p >> 7) & 1) ? '1' : '0', - ((*p >> 6) & 1) ? '1' : '0', ((*p >> 5) & 1) ? '1' : '0', - ((*p >> 4) & 1) ? '1' : '0', ((*p >> 3) & 1) ? '1' : '0', - ((*p >> 2) & 1) ? '1' : '0', ((*p >> 1) & 1) ? '1' : '0', - ((*p >> 0) & 1) ? '1' : '0'); + ((*p >> 6) & 1) ? '1' : '0', ((*p >> 5) & 1) ? '1' : '0', + ((*p >> 4) & 1) ? '1' : '0', ((*p >> 3) & 1) ? '1' : '0', + ((*p >> 2) & 1) ? '1' : '0', ((*p >> 1) & 1) ? '1' : '0', + ((*p >> 0) & 1) ? '1' : '0'); } if (DynamicBuffer.unbits) { @@ -474,7 +473,7 @@ static void buffer_dump() for (shift = 7; shift >= DynamicBuffer.unbits; shift--) fprintf(stderr, "%c", ((*p >> shift) & 1) ? '1' : '0'); fprintf(stderr, " %ld:%ld\n", (long)DynamicBuffer.length - 1, - (long)8 - DynamicBuffer.unbits); + (long)8 - DynamicBuffer.unbits); } else { @@ -495,8 +494,8 @@ static void buffer_shift_left(size_t offset, int bits) if (!bits) return; DEBUG("Shifting left %d bits off %ld (o=%ld, u=%ld, l=%ld)", bits, - (long)offset, (long)DynamicBuffer.offset, (long)DynamicBuffer.unbits, - (long)DynamicBuffer.length); + (long)offset, (long)DynamicBuffer.offset, (long)DynamicBuffer.unbits, + (long)DynamicBuffer.length); if (offset) { @@ -504,22 +503,22 @@ static void buffer_shift_left(size_t offset, int bits) right = ptr[0] >> (8 - bits); DEBUG("oleft: %c%c%c%c%c%c%c%c", ((ptr[-1] >> 7) & 1) ? '1' : '0', - ((ptr[-1] >> 6) & 1) ? '1' : '0', - ((ptr[-1] >> 5) & 1) ? '1' : '0', - ((ptr[-1] >> 4) & 1) ? '1' : '0', - ((ptr[-1] >> 3) & 1) ? '1' : '0', - ((ptr[-1] >> 2) & 1) ? '1' : '0', - ((ptr[-1] >> 1) & 1) ? '1' : '0', - ((ptr[-1] >> 0) & 1) ? '1' : '0'); + ((ptr[-1] >> 6) & 1) ? '1' : '0', + ((ptr[-1] >> 5) & 1) ? '1' : '0', + ((ptr[-1] >> 4) & 1) ? '1' : '0', + ((ptr[-1] >> 3) & 1) ? '1' : '0', + ((ptr[-1] >> 2) & 1) ? '1' : '0', + ((ptr[-1] >> 1) & 1) ? '1' : '0', + ((ptr[-1] >> 0) & 1) ? '1' : '0'); DEBUG("oriht: %c%c%c%c%c%c%c%c", ((ptr[0] >> 7) & 1) ? '1' : '0', - ((ptr[0] >> 6) & 1) ? '1' : '0', - ((ptr[0] >> 5) & 1) ? '1' : '0', - ((ptr[0] >> 4) & 1) ? '1' : '0', - ((ptr[0] >> 3) & 1) ? '1' : '0', - ((ptr[0] >> 2) & 1) ? '1' : '0', - ((ptr[0] >> 1) & 1) ? '1' : '0', - ((ptr[0] >> 0) & 1) ? '1' : '0'); + ((ptr[0] >> 6) & 1) ? '1' : '0', + ((ptr[0] >> 5) & 1) ? '1' : '0', + ((ptr[0] >> 4) & 1) ? '1' : '0', + ((ptr[0] >> 3) & 1) ? '1' : '0', + ((ptr[0] >> 2) & 1) ? '1' : '0', + ((ptr[0] >> 1) & 1) ? '1' : '0', + ((ptr[0] >> 0) & 1) ? '1' : '0'); DEBUG( "mriht: %c%c%c%c%c%c%c%c", ((right >> 7) & 1) ? '1' : '0', @@ -531,13 +530,13 @@ static void buffer_shift_left(size_t offset, int bits) ptr[-1] = (ptr[-1] & (0xff << bits)) | right; DEBUG("after: %c%c%c%c%c%c%c%c", ((ptr[-1] >> 7) & 1) ? '1' : '0', - ((ptr[-1] >> 6) & 1) ? '1' : '0', - ((ptr[-1] >> 5) & 1) ? '1' : '0', - ((ptr[-1] >> 4) & 1) ? '1' : '0', - ((ptr[-1] >> 3) & 1) ? '1' : '0', - ((ptr[-1] >> 2) & 1) ? '1' : '0', - ((ptr[-1] >> 1) & 1) ? '1' : '0', - ((ptr[-1] >> 0) & 1) ? '1' : '0'); + ((ptr[-1] >> 6) & 1) ? '1' : '0', + ((ptr[-1] >> 5) & 1) ? '1' : '0', + ((ptr[-1] >> 4) & 1) ? '1' : '0', + ((ptr[-1] >> 3) & 1) ? '1' : '0', + ((ptr[-1] >> 2) & 1) ? '1' : '0', + ((ptr[-1] >> 1) & 1) ? '1' : '0', + ((ptr[-1] >> 0) & 1) ? '1' : '0'); } buffer_dump(); @@ -569,7 +568,7 @@ static void buffer_shift_left(size_t offset, int bits) buffer_dump(); DEBUG("Shifted. Now (o=%ld, u=%ld l=%ld)", (long)DynamicBuffer.offset, - (long)DynamicBuffer.unbits, (long)DynamicBuffer.length); + (long)DynamicBuffer.unbits, (long)DynamicBuffer.length); } /* @@ -580,8 +579,8 @@ static void add_bytes_to_buffer(const void *data2add, size_t bytes) if (bytes == 0) return; DEBUG("=> add_bytes(%ld) { o=%ld l=%ld u=%ld, s=%ld }", (long)bytes, - (long)DynamicBuffer.offset, (long)DynamicBuffer.length, - (long)DynamicBuffer.unbits, (long)DynamicBuffer.allocated); + (long)DynamicBuffer.offset, (long)DynamicBuffer.length, + (long)DynamicBuffer.unbits, (long)DynamicBuffer.allocated); if (DynamicBuffer.allocated >= (DynamicBuffer.offset + DynamicBuffer.length + bytes)) @@ -594,8 +593,8 @@ static void add_bytes_to_buffer(const void *data2add, size_t bytes) /* Shift the buffer contents */ memmove(DynamicBuffer.data, - DynamicBuffer.data + DynamicBuffer.offset, - DynamicBuffer.length); + DynamicBuffer.data + DynamicBuffer.offset, + DynamicBuffer.length); DynamicBuffer.bytes_shifted += DynamicBuffer.offset; DynamicBuffer.offset = 0; } @@ -609,18 +608,18 @@ static void add_bytes_to_buffer(const void *data2add, size_t bytes) exit(EX_OSERR); } memcpy(p, DynamicBuffer.data + DynamicBuffer.offset, - DynamicBuffer.length); + DynamicBuffer.length); FREEMEM(DynamicBuffer.data); DynamicBuffer.data = (uint8_t *)p; DynamicBuffer.offset = 0; DynamicBuffer.allocated = newsize; DynamicBuffer.nreallocs++; DEBUG("\tBuffer reallocated to %ld (%d time)", newsize, - DynamicBuffer.nreallocs); + DynamicBuffer.nreallocs); } memcpy(DynamicBuffer.data + DynamicBuffer.offset + DynamicBuffer.length, - data2add, bytes); + data2add, bytes); DynamicBuffer.length += bytes; if (DynamicBuffer.unbits) { @@ -630,13 +629,13 @@ static void add_bytes_to_buffer(const void *data2add, size_t bytes) } DEBUG("<= add_bytes(%ld) { o=%ld l=%ld u=%ld, s=%ld }", (long)bytes, - (long)DynamicBuffer.offset, (long)DynamicBuffer.length, - (long)DynamicBuffer.unbits, (long)DynamicBuffer.allocated); + (long)DynamicBuffer.offset, (long)DynamicBuffer.length, + (long)DynamicBuffer.unbits, (long)DynamicBuffer.allocated); } static void *data_decode_from_file(asn_TYPE_descriptor_t *pduType, FILE *file, - const char *name, ssize_t suggested_bufsize, - int on_first_pdu) + const char *name, ssize_t suggested_bufsize, + int on_first_pdu) { static uint8_t *fbuf; static ssize_t fbuf_size; @@ -724,50 +723,50 @@ static void *data_decode_from_file(asn_TYPE_descriptor_t *pduType, FILE *file, switch (iform) { - case INP_BER: - rval = ber_decode(opt_codec_ctx, pduType, &structure, - i_bptr, i_size); - break; - case INP_XER: - rval = xer_decode(opt_codec_ctx, pduType, &structure, - i_bptr, i_size); - break; - case INP_PER: - if (opt_nopad) - rval = uper_decode(opt_codec_ctx, pduType, - &structure, i_bptr, i_size, 0, - DynamicBuffer.unbits); - else - rval = uper_decode_complete(opt_codec_ctx, pduType, - &structure, i_bptr, - i_size); - switch (rval.code) - { - case RC_OK: - /* Fall through */ - case RC_FAIL: - if (opt_nopad) - { - /* uper_decode() returns bits! */ - /* Extra bits */ - ecbits = rval.consumed % 8; - /* Convert into bytes! */ - rval.consumed /= 8; - } - break; - case RC_WMORE: - /* PER does not support restartability */ - ASN_STRUCT_FREE(*pduType, structure); - structure = 0; - rval.consumed = 0; - /* Continue accumulating data */ - break; - } - break; + case INP_BER: + rval = ber_decode(opt_codec_ctx, pduType, &structure, + i_bptr, i_size); + break; + case INP_XER: + rval = xer_decode(opt_codec_ctx, pduType, &structure, + i_bptr, i_size); + break; + case INP_PER: + if (opt_nopad) + rval = uper_decode(opt_codec_ctx, pduType, + &structure, i_bptr, i_size, 0, + DynamicBuffer.unbits); + else + rval = uper_decode_complete(opt_codec_ctx, pduType, + &structure, i_bptr, + i_size); + switch (rval.code) + { + case RC_OK: + /* Fall through */ + case RC_FAIL: + if (opt_nopad) + { + /* uper_decode() returns bits! */ + /* Extra bits */ + ecbits = rval.consumed % 8; + /* Convert into bytes! */ + rval.consumed /= 8; + } + break; + case RC_WMORE: + /* PER does not support restartability */ + ASN_STRUCT_FREE(*pduType, structure); + structure = 0; + rval.consumed = 0; + /* Continue accumulating data */ + break; + } + break; } DEBUG("decode(%ld) consumed %ld+%db (%ld), code %d", - (long)DynamicBuffer.length, (long)rval.consumed, ecbits, - (long)i_size, rval.code); + (long)DynamicBuffer.length, (long)rval.consumed, ecbits, + (long)i_size, rval.code); if (DynamicBuffer.allocated == 0) { @@ -777,7 +776,7 @@ static void *data_decode_from_file(asn_TYPE_descriptor_t *pduType, FILE *file, if (rval.code != RC_FAIL && rval.consumed < rd) { add_bytes_to_buffer(fbuf + rval.consumed, - rd - rval.consumed); + rd - rval.consumed); buffer_shift_left(0, ecbits); DynamicBuffer.bytes_shifted = rval.consumed; rval.consumed = 0; @@ -800,24 +799,24 @@ static void *data_decode_from_file(asn_TYPE_descriptor_t *pduType, FILE *file, switch (rval.code) { - case RC_OK: - if (ecbits) buffer_shift_left(0, ecbits); - DEBUG("RC_OK, finishing up with %ld+%d", - (long)rval.consumed, ecbits); - return structure; - case RC_WMORE: - DEBUG( - "RC_WMORE, continuing read=%ld, cons=%ld " - " with %ld..%ld-%ld..%ld", - (long)rd, (long)rval.consumed, - (long)DynamicBuffer.offset, - (long)DynamicBuffer.length, - (long)DynamicBuffer.unbits, - (long)DynamicBuffer.allocated); - if (!rd) tolerate_eof--; - continue; - case RC_FAIL: - break; + case RC_OK: + if (ecbits) buffer_shift_left(0, ecbits); + DEBUG("RC_OK, finishing up with %ld+%d", + (long)rval.consumed, ecbits); + return structure; + case RC_WMORE: + DEBUG( + "RC_WMORE, continuing read=%ld, cons=%ld " + " with %ld..%ld-%ld..%ld", + (long)rd, (long)rval.consumed, + (long)DynamicBuffer.offset, + (long)DynamicBuffer.length, + (long)DynamicBuffer.unbits, + (long)DynamicBuffer.allocated); + if (!rd) tolerate_eof--; + continue; + case RC_FAIL: + break; } break; } @@ -848,14 +847,14 @@ static void *data_decode_from_file(asn_TYPE_descriptor_t *pduType, FILE *file, #endif DEBUG("ofp %d, no=%ld, oo=%ld, dbl=%ld", on_first_pdu, - (long)new_offset, (long)old_offset, - (long)DynamicBuffer.length); + (long)new_offset, (long)old_offset, + (long)DynamicBuffer.length); fprintf(stderr, - "%s: " - "Decode failed past byte %ld: %s\n", - name, (long)new_offset, - (rval.code == RC_WMORE) ? "Unexpected end of input" - : "Input processing error"); + "%s: " + "Decode failed past byte %ld: %s\n", + name, (long)new_offset, + (rval.code == RC_WMORE) ? "Unexpected end of input" + : "Input processing error"); #ifndef ENOMSG #define ENOMSG EINVAL #endif diff --git a/src/core/libs/supl/asn-rrlp/der_encoder.c b/src/core/libs/supl/asn-rrlp/der_encoder.c index 5c6aeab10..b65475a4d 100644 --- a/src/core/libs/supl/asn-rrlp/der_encoder.c +++ b/src/core/libs/supl/asn-rrlp/der_encoder.c @@ -6,15 +6,15 @@ #include static ssize_t der_write_TL(ber_tlv_tag_t tag, ber_tlv_len_t len, - asn_app_consume_bytes_f *cb, void *app_key, - int constructed); + asn_app_consume_bytes_f *cb, void *app_key, + int constructed); /* * The DER encoder of any type. */ asn_enc_rval_t der_encode(asn_TYPE_descriptor_t *type_descriptor, - void *struct_ptr, - asn_app_consume_bytes_f *consume_bytes, void *app_key) + void *struct_ptr, + asn_app_consume_bytes_f *consume_bytes, void *app_key) { ASN_DEBUG("DER encoder invoked for %s", type_descriptor->name); @@ -52,8 +52,8 @@ static int encode_to_buffer_cb(const void *buffer, size_t size, void *key) * A variant of the der_encode() which encodes the data into the provided buffer */ asn_enc_rval_t der_encode_to_buffer(asn_TYPE_descriptor_t *type_descriptor, - void *struct_ptr, void *buffer, - size_t buffer_size) + void *struct_ptr, void *buffer, + size_t buffer_size) { enc_to_buf_arg arg; asn_enc_rval_t ec; @@ -76,9 +76,9 @@ asn_enc_rval_t der_encode_to_buffer(asn_TYPE_descriptor_t *type_descriptor, * Write out leading TL[v] sequence according to the type definition. */ ssize_t der_write_tags(asn_TYPE_descriptor_t *sd, size_t struct_length, - int tag_mode, int last_tag_form, - ber_tlv_tag_t tag, /* EXPLICIT or IMPLICIT tag */ - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, int last_tag_form, + ber_tlv_tag_t tag, /* EXPLICIT or IMPLICIT tag */ + asn_app_consume_bytes_f *cb, void *app_key) { ber_tlv_tag_t *tags; /* Copy of tags stream */ int tags_count; /* Number of tags */ @@ -87,10 +87,10 @@ ssize_t der_write_tags(asn_TYPE_descriptor_t *sd, size_t struct_length, int i; ASN_DEBUG("Writing tags (%s, tm=%d, tc=%d, tag=%s, mtc=%d)", sd->name, - tag_mode, sd->tags_count, ber_tlv_tag_string(tag), - tag_mode - ? (sd->tags_count + 1 - ((tag_mode == -1) && sd->tags_count)) - : sd->tags_count); + tag_mode, sd->tags_count, ber_tlv_tag_string(tag), + tag_mode + ? (sd->tags_count + 1 - ((tag_mode == -1) && sd->tags_count)) + : sd->tags_count); if (tag_mode) { @@ -148,7 +148,7 @@ ssize_t der_write_tags(asn_TYPE_descriptor_t *sd, size_t struct_length, if (!cb) return overall_length - struct_length; ASN_DEBUG("%s %s TL sequence (%d elements)", cb ? "Encoding" : "Estimating", - sd->name, tags_count); + sd->name, tags_count); /* * Encode the TL sequence for real. @@ -169,8 +169,8 @@ ssize_t der_write_tags(asn_TYPE_descriptor_t *sd, size_t struct_length, } static ssize_t der_write_TL(ber_tlv_tag_t tag, ber_tlv_len_t len, - asn_app_consume_bytes_f *cb, void *app_key, - int constructed) + asn_app_consume_bytes_f *cb, void *app_key, + int constructed) { uint8_t buf[32]; size_t size = 0; @@ -184,7 +184,7 @@ static ssize_t der_write_TL(ber_tlv_tag_t tag, ber_tlv_len_t len, /* Serialize length (L from TLV) into possibly zero-length buffer */ tmp = der_tlv_length_serialize(len, buf + size, - buf_size ? buf_size - size : 0); + buf_size ? buf_size - size : 0); if (tmp == -1) return -1; size += tmp; diff --git a/src/core/libs/supl/asn-rrlp/der_encoder.h b/src/core/libs/supl/asn-rrlp/der_encoder.h index 4a8e6d001..c55761c75 100644 --- a/src/core/libs/supl/asn-rrlp/der_encoder.h +++ b/src/core/libs/supl/asn-rrlp/der_encoder.h @@ -19,9 +19,9 @@ extern "C" * The ber_decode() function (ber_decoder.h) is an opposite of der_encode(). */ asn_enc_rval_t der_encode(struct asn_TYPE_descriptor_s *type_descriptor, - void *struct_ptr, /* Structure to be encoded */ - asn_app_consume_bytes_f *consume_bytes_cb, - void *app_key /* Arbitrary callback argument */ + void *struct_ptr, /* Structure to be encoded */ + asn_app_consume_bytes_f *consume_bytes_cb, + void *app_key /* Arbitrary callback argument */ ); /* A variant of der_encode() which encodes data into the pre-allocated @@ -42,7 +42,7 @@ extern "C" int tag_mode, /* {-1,0,1}: IMPLICIT, no, EXPLICIT */ ber_tlv_tag_t tag, asn_app_consume_bytes_f *consume_bytes_cb, /* Callback */ - void *app_key /* Arbitrary callback argument */ + void *app_key /* Arbitrary callback argument */ ); /******************************* @@ -53,12 +53,12 @@ extern "C" * Write out leading TL[v] sequence according to the type definition. */ ssize_t der_write_tags(struct asn_TYPE_descriptor_s *type_descriptor, - size_t struct_length, - int tag_mode, /* {-1,0,1}: IMPLICIT, no, EXPLICIT */ - int last_tag_form, /* {0,!0}: prim, constructed */ - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *consume_bytes_cb, - void *app_key); + size_t struct_length, + int tag_mode, /* {-1,0,1}: IMPLICIT, no, EXPLICIT */ + int last_tag_form, /* {0,!0}: prim, constructed */ + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *consume_bytes_cb, + void *app_key); #ifdef __cplusplus } diff --git a/src/core/libs/supl/asn-rrlp/per_decoder.c b/src/core/libs/supl/asn-rrlp/per_decoder.c index b5dd27229..cb9effce6 100644 --- a/src/core/libs/supl/asn-rrlp/per_decoder.c +++ b/src/core/libs/supl/asn-rrlp/per_decoder.c @@ -8,8 +8,8 @@ * multiple of 8 bytes. */ asn_dec_rval_t uper_decode_complete(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **sptr, - const void *buffer, size_t size) + asn_TYPE_descriptor_t *td, void **sptr, + const void *buffer, size_t size) { asn_dec_rval_t rval; @@ -48,9 +48,9 @@ asn_dec_rval_t uper_decode_complete(asn_codec_ctx_t *opt_codec_ctx, } asn_dec_rval_t uper_decode(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **sptr, - const void *buffer, size_t size, int skip_bits, - int unused_bits) + asn_TYPE_descriptor_t *td, void **sptr, + const void *buffer, size_t size, int skip_bits, + int unused_bits) { asn_codec_ctx_t s_codec_ctx; asn_dec_rval_t rval; @@ -98,7 +98,7 @@ asn_dec_rval_t uper_decode(asn_codec_ctx_t *opt_codec_ctx, rval.consumed = ((pd.buffer - (const uint8_t *)buffer) << 3) + pd.nboff - skip_bits; ASN_DEBUG("PER decoding consumed %d, counted %d", rval.consumed, - pd.moved); + pd.moved); assert(rval.consumed == pd.moved); } else diff --git a/src/core/libs/supl/asn-rrlp/per_decoder.h b/src/core/libs/supl/asn-rrlp/per_decoder.h index ecb3b52eb..95a35364f 100644 --- a/src/core/libs/supl/asn-rrlp/per_decoder.h +++ b/src/core/libs/supl/asn-rrlp/per_decoder.h @@ -23,9 +23,9 @@ extern "C" asn_dec_rval_t uper_decode_complete( struct asn_codec_ctx_s *opt_codec_ctx, struct asn_TYPE_descriptor_s *type_descriptor, /* Type to decode */ - void **struct_ptr, /* Pointer to a target structure's pointer */ - const void *buffer, /* Data to be decoded */ - size_t size /* Size of data buffer */ + void **struct_ptr, /* Pointer to a target structure's pointer */ + const void *buffer, /* Data to be decoded */ + size_t size /* Size of data buffer */ ); /* @@ -36,11 +36,11 @@ extern "C" asn_dec_rval_t uper_decode( struct asn_codec_ctx_s *opt_codec_ctx, struct asn_TYPE_descriptor_s *type_descriptor, /* Type to decode */ - void **struct_ptr, /* Pointer to a target structure's pointer */ - const void *buffer, /* Data to be decoded */ - size_t size, /* Size of data buffer */ - int skip_bits, /* Number of unused leading bits, 0..7 */ - int unused_bits /* Number of unused tailing bits, 0..7 */ + void **struct_ptr, /* Pointer to a target structure's pointer */ + const void *buffer, /* Data to be decoded */ + size_t size, /* Size of data buffer */ + int skip_bits, /* Number of unused leading bits, 0..7 */ + int unused_bits /* Number of unused tailing bits, 0..7 */ ); /* diff --git a/src/core/libs/supl/asn-rrlp/per_encoder.c b/src/core/libs/supl/asn-rrlp/per_encoder.c index af7678a8b..b0013b1ff 100644 --- a/src/core/libs/supl/asn-rrlp/per_encoder.c +++ b/src/core/libs/supl/asn-rrlp/per_encoder.c @@ -7,7 +7,7 @@ static asn_enc_rval_t uper_encode_internal( void *sptr, asn_app_consume_bytes_f *cb, void *app_key); asn_enc_rval_t uper_encode(asn_TYPE_descriptor_t *td, void *sptr, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { return uper_encode_internal(td, 0, sptr, cb, app_key); } @@ -35,7 +35,7 @@ static int encode_to_buffer_cb(const void *buffer, size_t size, void *key) } asn_enc_rval_t uper_encode_to_buffer(asn_TYPE_descriptor_t *td, void *sptr, - void *buffer, size_t buffer_size) + void *buffer, size_t buffer_size) { enc_to_buf_arg key; @@ -74,8 +74,8 @@ static int encode_dyn_cb(const void *buffer, size_t size, void *key) return 0; } ssize_t uper_encode_to_new_buffer(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *sptr, void **buffer_r) + asn_per_constraints_t *constraints, + void *sptr, void **buffer_r) { asn_enc_rval_t er; enc_dyn_arg key; @@ -85,26 +85,26 @@ ssize_t uper_encode_to_new_buffer(asn_TYPE_descriptor_t *td, er = uper_encode_internal(td, constraints, sptr, encode_dyn_cb, &key); switch (er.encoded) { - case -1: - FREEMEM(key.buffer); - return -1; - case 0: - FREEMEM(key.buffer); - key.buffer = MALLOC(1); - if (key.buffer) - { - *(char *)key.buffer = '\0'; - *buffer_r = key.buffer; - return 1; - } - else - { - return -1; - } - default: - *buffer_r = key.buffer; - ASN_DEBUG("Complete encoded in %d bits", er.encoded); - return ((er.encoded + 7) >> 3); + case -1: + FREEMEM(key.buffer); + return -1; + case 0: + FREEMEM(key.buffer); + key.buffer = MALLOC(1); + if (key.buffer) + { + *(char *)key.buffer = '\0'; + *buffer_r = key.buffer; + return 1; + } + else + { + return -1; + } + default: + *buffer_r = key.buffer; + ASN_DEBUG("Complete encoded in %d bits", er.encoded); + return ((er.encoded + 7) >> 3); } } @@ -131,10 +131,10 @@ static int _uper_encode_flush_outp(asn_per_outp_t *po) } static asn_enc_rval_t uper_encode_internal(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *sptr, - asn_app_consume_bytes_f *cb, - void *app_key) + asn_per_constraints_t *constraints, + void *sptr, + asn_app_consume_bytes_f *cb, + void *app_key) { asn_per_outp_t po; asn_enc_rval_t er; diff --git a/src/core/libs/supl/asn-rrlp/per_encoder.h b/src/core/libs/supl/asn-rrlp/per_encoder.h index 3c1568595..a1726a9bf 100644 --- a/src/core/libs/supl/asn-rrlp/per_encoder.h +++ b/src/core/libs/supl/asn-rrlp/per_encoder.h @@ -25,7 +25,7 @@ extern "C" struct asn_TYPE_descriptor_s *type_descriptor, void *struct_ptr, /* Structure to be encoded */ asn_app_consume_bytes_f *consume_bytes_cb, /* Data collector */ - void *app_key /* Arbitrary callback argument */ + void *app_key /* Arbitrary callback argument */ ); /* diff --git a/src/core/libs/supl/asn-rrlp/per_opentype.c b/src/core/libs/supl/asn-rrlp/per_opentype.c index 5a2921406..5a91e77ae 100644 --- a/src/core/libs/supl/asn-rrlp/per_opentype.c +++ b/src/core/libs/supl/asn-rrlp/per_opentype.c @@ -3,9 +3,9 @@ * Redistribution and modifications are permitted subject to BSD license. */ #include -#include #include #include +#include typedef struct uper_ugot_key { @@ -18,9 +18,9 @@ typedef struct uper_ugot_key static int uper_ugot_refill(asn_per_data_t *pd); static int per_skip_bits(asn_per_data_t *pd, int skip_nbits); static asn_dec_rval_t uper_sot_suck(asn_codec_ctx_t * /*ctx*/, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd); + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd); int asn_debug_indent; @@ -29,8 +29,8 @@ int asn_debug_indent; * #10.1, #10.2 */ int uper_open_type_put(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, void *sptr, - asn_per_outp_t *po) + asn_per_constraints_t *constraints, void *sptr, + asn_per_outp_t *po) { void *buf; void *bptr; @@ -55,7 +55,7 @@ int uper_open_type_put(asn_TYPE_descriptor_t *td, if (toGo) return -1; ASN_DEBUG("Open type put %s of length %d + overhead (1byte?)", td->name, - size); + size); return 0; } @@ -190,8 +190,8 @@ static asn_dec_rval_t GCC_NOTUSED uper_open_type_get_complex( } ASN_DEBUG("OpenType %s pd%s old%s unclaimed=%d, repeat=%d", td->name, - per_data_string(pd), per_data_string(&arg.oldpd), arg.unclaimed, - arg.repeat); + per_data_string(pd), per_data_string(&arg.oldpd), arg.unclaimed, + arg.repeat); padding = pd->moved % 8; if (padding) @@ -209,23 +209,23 @@ static asn_dec_rval_t GCC_NOTUSED uper_open_type_get_complex( pvalue = per_get_few_bits(pd, padding); switch (pvalue) { - case -1: - ASN_DEBUG("Padding skip failed"); - UPDRESTOREPD; - _ASN_DECODE_STARVED; - case 0: - break; - default: - ASN_DEBUG("Non-blank padding (%d bits 0x%02x)", padding, - (int)pvalue); - UPDRESTOREPD; - _ASN_DECODE_FAILED; + case -1: + ASN_DEBUG("Padding skip failed"); + UPDRESTOREPD; + _ASN_DECODE_STARVED; + case 0: + break; + default: + ASN_DEBUG("Non-blank padding (%d bits 0x%02x)", padding, + (int)pvalue); + UPDRESTOREPD; + _ASN_DECODE_FAILED; } } if (pd->nboff != pd->nbits) { ASN_DEBUG("Open type %s overhead pd%s old%s", td->name, - per_data_string(pd), per_data_string(&arg.oldpd)); + per_data_string(pd), per_data_string(&arg.oldpd)); if (1) { UPDRESTOREPD; @@ -246,16 +246,16 @@ static asn_dec_rval_t GCC_NOTUSED uper_open_type_get_complex( { switch (per_skip_bits(pd, arg.unclaimed)) { - case -1: - ASN_DEBUG("Claim of %d failed", arg.unclaimed); - _ASN_DECODE_STARVED; - case 0: - ASN_DEBUG("Got claim of %d", arg.unclaimed); - break; - default: - /* Padding must be blank */ - ASN_DEBUG("Non-blank unconsumed padding"); - _ASN_DECODE_FAILED; + case -1: + ASN_DEBUG("Claim of %d failed", arg.unclaimed); + _ASN_DECODE_STARVED; + case 0: + ASN_DEBUG("Got claim of %d", arg.unclaimed); + break; + default: + /* Padding must be blank */ + ASN_DEBUG("Non-blank unconsumed padding"); + _ASN_DECODE_FAILED; } arg.unclaimed = 0; } @@ -271,9 +271,9 @@ static asn_dec_rval_t GCC_NOTUSED uper_open_type_get_complex( } asn_dec_rval_t uper_open_type_get(asn_codec_ctx_t *ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd) { return uper_open_type_get_simple(ctx, td, constraints, sptr, pd); } @@ -298,9 +298,9 @@ int uper_open_type_skip(asn_codec_ctx_t *ctx, asn_per_data_t *pd) */ static asn_dec_rval_t uper_sot_suck(asn_codec_ctx_t *ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd) { asn_dec_rval_t rv; @@ -328,7 +328,7 @@ static int uper_ugot_refill(asn_per_data_t *pd) asn_per_data_t *oldpd = &arg->oldpd; ASN_DEBUG("REFILLING pd->moved=%d, oldpd->moved=%d", pd->moved, - oldpd->moved); + oldpd->moved); /* Advance our position to where pd is */ oldpd->buffer = pd->buffer; @@ -361,7 +361,7 @@ static int uper_ugot_refill(asn_per_data_t *pd) next_chunk_bytes = uper_get_length(oldpd, -1, &arg->repeat); ASN_DEBUG("Open type LENGTH %d bytes at off %d, repeat %d", - next_chunk_bytes, oldpd->moved, arg->repeat); + next_chunk_bytes, oldpd->moved, arg->repeat); if (next_chunk_bytes < 0) return -1; if (next_chunk_bytes == 0) { @@ -375,20 +375,20 @@ static int uper_ugot_refill(asn_per_data_t *pd) pd->nbits = oldpd->nboff + next_chunk_bits; arg->unclaimed = 0; ASN_DEBUG("!+Parent frame %d bits, alloting %d [%d..%d] (%d)", - next_chunk_bits, oldpd->moved, oldpd->nboff, oldpd->nbits, - oldpd->nbits - oldpd->nboff); + next_chunk_bits, oldpd->moved, oldpd->nboff, oldpd->nbits, + oldpd->nbits - oldpd->nboff); } else { pd->nbits = oldpd->nbits; arg->unclaimed = next_chunk_bits - avail; ASN_DEBUG("!-Parent frame %d, require %d, will claim %d", avail, - next_chunk_bits, arg->unclaimed); + next_chunk_bits, arg->unclaimed); } pd->buffer = oldpd->buffer; pd->nboff = oldpd->nboff; ASN_DEBUG("Refilled pd%s old%s", per_data_string(pd), - per_data_string(oldpd)); + per_data_string(oldpd)); return 0; } @@ -406,13 +406,13 @@ static int per_skip_bits(asn_per_data_t *pd, int skip_nbits) switch (per_get_few_bits(pd, skip)) { - case -1: - return -1; /* Starving */ - case 0: - continue; /* Skipped empty space */ - default: - hasNonZeroBits = 1; - continue; + case -1: + return -1; /* Starving */ + case 0: + continue; /* Skipped empty space */ + default: + hasNonZeroBits = 1; + continue; } } return hasNonZeroBits; diff --git a/src/core/libs/supl/asn-rrlp/per_opentype.h b/src/core/libs/supl/asn-rrlp/per_opentype.h index 1d1a7befa..a41ce9e15 100644 --- a/src/core/libs/supl/asn-rrlp/per_opentype.h +++ b/src/core/libs/supl/asn-rrlp/per_opentype.h @@ -11,15 +11,15 @@ extern "C" #endif asn_dec_rval_t uper_open_type_get(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd); + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd); int uper_open_type_skip(asn_codec_ctx_t *opt_codec_ctx, asn_per_data_t *pd); int uper_open_type_put(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, void *sptr, - asn_per_outp_t *po); + asn_per_constraints_t *constraints, void *sptr, + asn_per_outp_t *po); #ifdef __cplusplus } diff --git a/src/core/libs/supl/asn-rrlp/per_support.c b/src/core/libs/supl/asn-rrlp/per_support.c index 936ac77cd..9fdc23629 100644 --- a/src/core/libs/supl/asn-rrlp/per_support.c +++ b/src/core/libs/supl/asn-rrlp/per_support.c @@ -3,8 +3,8 @@ * All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ -#include #include +#include #include char *per_data_string(asn_per_data_t *pd) @@ -13,8 +13,8 @@ char *per_data_string(asn_per_data_t *pd) static int n; n = (n + 1) % 2; snprintf(buf[n], sizeof(buf[n]), "{m=%ld span %+ld[%d..%d] (%d)}", - (long)pd->moved, (((long)pd->buffer) & 0xf), (int)pd->nboff, - (int)pd->nbits, (int)(pd->nbits - pd->nboff)); + (long)pd->moved, (((long)pd->buffer) & 0xf), (int)pd->nboff, + (int)pd->nbits, (int)(pd->nbits - pd->nboff)); return buf[n]; } @@ -285,7 +285,7 @@ int uper_put_nsnnwn(asn_per_outp_t *po, int n) /* X.691-2008/11, #11.5.6 -> #11.3 */ int uper_get_constrained_whole_number(asn_per_data_t *pd, - unsigned long *out_value, int nbits) + unsigned long *out_value, int nbits) { unsigned long lhalf; /* Lower half of the number*/ long half; @@ -326,7 +326,7 @@ int uper_put_constrained_whole_number_s(asn_per_outp_t *po, long v, int nbits) } int uper_put_constrained_whole_number_u(asn_per_outp_t *po, unsigned long v, - int nbits) + int nbits) { if (nbits <= 31) { @@ -378,7 +378,7 @@ int per_put_few_bits(asn_per_outp_t *po, uint32_t bits, int obits) if (obits <= 0 || obits >= 32) return obits ? -1 : 0; ASN_DEBUG("[PER put %d bits %x to %p+%d bits]", obits, (int)bits, - po->buffer, (int)po->nboff); + po->buffer, (int)po->nboff); /* * Normalize position indicator. @@ -399,7 +399,7 @@ int per_put_few_bits(asn_per_outp_t *po, uint32_t bits, int obits) if (!po->buffer) po->buffer = po->tmpspace; complete_bytes = (po->buffer - po->tmpspace); ASN_DEBUG("[PER output %ld complete + %ld]", (long)complete_bytes, - (long)po->flushed_bytes); + (long)po->flushed_bytes); if (po->outper(po->tmpspace, complete_bytes, po->op_key) < 0) return -1; if (po->nboff) po->tmpspace[0] = po->buffer[0]; @@ -419,8 +419,8 @@ int per_put_few_bits(asn_per_outp_t *po, uint32_t bits, int obits) bits &= (((uint32_t)1 << obits) - 1); ASN_DEBUG("[PER out %d %u/%x (t=%d,o=%d) %x&%x=%x]", obits, (int)bits, - (int)bits, (int)po->nboff, (int)off, buf[0], (int)(omsk & 0xff), - (int)(buf[0] & omsk)); + (int)bits, (int)po->nboff, (int)off, buf[0], (int)(omsk & 0xff), + (int)(buf[0] & omsk)); if (off <= 8) /* Completely within 1 byte */ po->nboff = off, bits <<= (8 - off), buf[0] = (buf[0] & omsk) | bits; @@ -446,7 +446,7 @@ int per_put_few_bits(asn_per_outp_t *po, uint32_t bits, int obits) } ASN_DEBUG("[PER out %u/%x => %02x buf+%ld]", (int)bits, (int)bits, buf[0], - (po->buffer - po->tmpspace)); + (po->buffer - po->tmpspace)); return 0; } diff --git a/src/core/libs/supl/asn-rrlp/per_support.h b/src/core/libs/supl/asn-rrlp/per_support.h index 53a7a4d92..43eab5e66 100644 --- a/src/core/libs/supl/asn-rrlp/per_support.h +++ b/src/core/libs/supl/asn-rrlp/per_support.h @@ -46,7 +46,7 @@ extern "C" const uint8_t *buffer; /* Pointer to the octet stream */ size_t nboff; /* Bit offset to the meaningful bit */ size_t nbits; /* Number of bits in the stream */ - size_t moved; /* Number of bits moved through this bit stream */ + size_t moved; /* Number of bits moved through this bit stream */ int (*refill)(struct asn_per_data_s *); void *refill_key; } asn_per_data_t; @@ -67,13 +67,13 @@ extern "C" * extracted due to EOD or other conditions. */ int per_get_many_bits(asn_per_data_t *pd, uint8_t *dst, int right_align, - int get_nbits); + int get_nbits); /* * Get the length "n" from the Unaligned PER stream. */ ssize_t uper_get_length(asn_per_data_t *pd, int effective_bound_bits, - int *repeat); + int *repeat); /* * Get the normally small length "n". @@ -87,7 +87,7 @@ extern "C" /* X.691-2008/11, #11.5.6 */ int uper_get_constrained_whole_number(asn_per_data_t *pd, unsigned long *v, - int nbits); + int nbits); /* Non-thread-safe debugging function, don't use it */ char *per_data_string(asn_per_data_t *pd); @@ -111,7 +111,7 @@ extern "C" /* Output a large number of bits */ int per_put_many_bits(asn_per_outp_t *po, const uint8_t *src, - int put_nbits); + int put_nbits); /* * Flush whole bytes (0 or more) through (outper) member. @@ -122,9 +122,9 @@ extern "C" /* X.691-2008/11, #11.5 */ int uper_put_constrained_whole_number_s(asn_per_outp_t *po, long v, - int nbits); + int nbits); int uper_put_constrained_whole_number_u(asn_per_outp_t *po, unsigned long v, - int nbits); + int nbits); /* * Put the length "n" to the Unaligned PER stream. diff --git a/src/core/libs/supl/asn-rrlp/xer_decoder.c b/src/core/libs/supl/asn-rrlp/xer_decoder.c index c7bc688bc..a027b0d11 100644 --- a/src/core/libs/supl/asn-rrlp/xer_decoder.c +++ b/src/core/libs/supl/asn-rrlp/xer_decoder.c @@ -10,8 +10,8 @@ * Decode the XER encoding of a given type. */ asn_dec_rval_t xer_decode(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **struct_ptr, - const void *buffer, size_t size) + asn_TYPE_descriptor_t *td, void **struct_ptr, + const void *buffer, size_t size) { asn_codec_ctx_t s_codec_ctx; @@ -50,7 +50,7 @@ struct xer__cb_arg }; static int xer__token_cb(pxml_chunk_type_e type, const void *_chunk_data, - size_t _chunk_size, void *key) + size_t _chunk_size, void *key) { struct xer__cb_arg *arg = (struct xer__cb_arg *)key; arg->chunk_type = type; @@ -64,7 +64,7 @@ static int xer__token_cb(pxml_chunk_type_e type, const void *_chunk_data, * Fetch the next token from the XER/XML stream. */ ssize_t xer_next_token(int *stateContext, const void *buffer, size_t size, - pxer_chunk_type_e *ch_type) + pxer_chunk_type_e *ch_type) { struct xer__cb_arg arg; int new_stateContext = *stateContext; @@ -89,18 +89,18 @@ ssize_t xer_next_token(int *stateContext, const void *buffer, size_t size, */ switch (arg.chunk_type) { - case PXML_TEXT: - *ch_type = PXER_TEXT; - break; - case PXML_TAG: - return 0; /* Want more */ - case PXML_TAG_END: - *ch_type = PXER_TAG; - break; - case PXML_COMMENT: - case PXML_COMMENT_END: - *ch_type = PXER_COMMENT; - break; + case PXML_TEXT: + *ch_type = PXER_TEXT; + break; + case PXML_TAG: + return 0; /* Want more */ + case PXML_TAG_END: + *ch_type = PXER_TAG; + break; + case PXML_COMMENT: + case PXML_COMMENT_END: + *ch_type = PXER_COMMENT; + break; } *stateContext = new_stateContext; @@ -112,7 +112,7 @@ ssize_t xer_next_token(int *stateContext, const void *buffer, size_t size, #define RANGLE 0x3e /* '>' */ xer_check_tag_e xer_check_tag(const void *buf_ptr, int size, - const char *need_tag) + const char *need_tag) { const char *buf = (const char *)buf_ptr; const char *end; @@ -163,13 +163,13 @@ xer_check_tag_e xer_check_tag(const void *buf_ptr, int size, { switch (b) { - case 0x09: - case 0x0a: - case 0x0c: - case 0x0d: - case 0x20: - /* "": whitespace is normal */ - return ct; + case 0x09: + case 0x0a: + case 0x0c: + case 0x0d: + case 0x20: + /* "": whitespace is normal */ + return ct; } } return (xer_check_tag_e)(XCT__UNK__MASK | ct); @@ -208,7 +208,7 @@ xer_check_tag_e xer_check_tag(const void *buf_ptr, int size, { \ ssize_t converted_size = \ body_receiver(struct_key, chunk_buf, chunk_size, \ - (size_t)(chunk_size) < (size)); \ + (size_t)(chunk_size) < (size)); \ if (converted_size == -1) RETURN(RC_FAIL); \ if (converted_size == 0 && (size) == (size_t)(chunk_size)) \ RETURN(RC_WMORE); \ @@ -232,9 +232,9 @@ asn_dec_rval_t xer_decode_general( void *struct_key, const char *xml_tag, /* Expected XML tag */ const void *buf_ptr, size_t size, int (*opt_unexpected_tag_decoder)(void *struct_key, const void *chunk_buf, - size_t chunk_size), + size_t chunk_size), ssize_t (*body_receiver)(void *struct_key, const void *chunk_buf, - size_t chunk_size, int have_more)) + size_t chunk_size, int have_more)) { asn_dec_rval_t rval; ssize_t consumed_myself = 0; @@ -259,37 +259,37 @@ asn_dec_rval_t xer_decode_general( ch_size = xer_next_token(&ctx->context, buf_ptr, size, &ch_type); switch (ch_size) { - case -1: - RETURN(RC_FAIL); - case 0: - RETURN(RC_WMORE); - default: - switch (ch_type) - { - case PXER_COMMENT: /* Got XML comment */ - ADVANCE(ch_size); /* Skip silently */ - continue; - case PXER_TEXT: - if (ctx->phase == 0) - { - /* + case -1: + RETURN(RC_FAIL); + case 0: + RETURN(RC_WMORE); + default: + switch (ch_type) + { + case PXER_COMMENT: /* Got XML comment */ + ADVANCE(ch_size); /* Skip silently */ + continue; + case PXER_TEXT: + if (ctx->phase == 0) + { + /* * We have to ignore whitespace * here, but in order to be forward * compatible with EXTENDED-XER * (EMBED-VALUES, #25) any text is * just ignored here. */ - } - else - { - XER_GOT_BODY(buf_ptr, ch_size, - size); - } - ADVANCE(ch_size); - continue; - case PXER_TAG: - break; /* Check the rest down there */ - } + } + else + { + XER_GOT_BODY(buf_ptr, ch_size, + size); + } + ADVANCE(ch_size); + continue; + case PXER_TAG: + break; /* Check the rest down there */ + } } assert(ch_type == PXER_TAG && size); @@ -304,45 +304,45 @@ asn_dec_rval_t xer_decode_general( */ switch (tcv) { - case XCT_BOTH: - if (ctx->phase) break; - /* Finished decoding of an empty element */ - XER_GOT_EMPTY(); - ADVANCE(ch_size); - ctx->phase = 2; /* Phase out */ - RETURN(RC_OK); - case XCT_OPENING: - if (ctx->phase) break; - ADVANCE(ch_size); - ctx->phase = 1; /* Processing body phase */ - continue; - case XCT_CLOSING: - if (!ctx->phase) break; - ADVANCE(ch_size); - ctx->phase = 2; /* Phase out */ - RETURN(RC_OK); - case XCT_UNKNOWN_BO: - /* + case XCT_BOTH: + if (ctx->phase) break; + /* Finished decoding of an empty element */ + XER_GOT_EMPTY(); + ADVANCE(ch_size); + ctx->phase = 2; /* Phase out */ + RETURN(RC_OK); + case XCT_OPENING: + if (ctx->phase) break; + ADVANCE(ch_size); + ctx->phase = 1; /* Processing body phase */ + continue; + case XCT_CLOSING: + if (!ctx->phase) break; + ADVANCE(ch_size); + ctx->phase = 2; /* Phase out */ + RETURN(RC_OK); + case XCT_UNKNOWN_BO: + /* * Certain tags in the body may be expected. */ - if (opt_unexpected_tag_decoder && - opt_unexpected_tag_decoder(struct_key, buf_ptr, - ch_size) >= 0) - { - /* Tag's processed fine */ - ADVANCE(ch_size); - if (!ctx->phase) - { - /* We are not expecting + if (opt_unexpected_tag_decoder && + opt_unexpected_tag_decoder(struct_key, buf_ptr, + ch_size) >= 0) + { + /* Tag's processed fine */ + ADVANCE(ch_size); + if (!ctx->phase) + { + /* We are not expecting * the closing tag anymore. */ - ctx->phase = 2; /* Phase out */ - RETURN(RC_OK); - } - continue; - } - /* Fall through */ - default: - break; /* Unexpected tag */ + ctx->phase = 2; /* Phase out */ + RETURN(RC_OK); + } + continue; + } + /* Fall through */ + default: + break; /* Unexpected tag */ } ASN_DEBUG("Unexpected XML tag (expected \"%s\")", xml_tag); @@ -361,19 +361,19 @@ int xer_is_whitespace(const void *chunk_buf, size_t chunk_size) { switch (*p) { - /* X.693, #8.1.4 + /* X.693, #8.1.4 * HORISONTAL TAB (9) * LINE FEED (10) * CARRIAGE RETURN (13) * SPACE (32) */ - case 0x09: - case 0x0a: - case 0x0d: - case 0x20: - break; - default: - return 0; + case 0x09: + case 0x0a: + case 0x0d: + case 0x20: + break; + default: + return 0; } } return 1; /* All whitespace */ @@ -387,19 +387,19 @@ int xer_skip_unknown(xer_check_tag_e tcv, ber_tlv_len_t *depth) assert(*depth > 0); switch (tcv) { - case XCT_BOTH: - case XCT_UNKNOWN_BO: - /* These negate each other. */ - return 0; - case XCT_OPENING: - case XCT_UNKNOWN_OP: - ++(*depth); - return 0; - case XCT_CLOSING: - case XCT_UNKNOWN_CL: - if (--(*depth) == 0) return (tcv == XCT_CLOSING) ? 2 : 1; - return 0; - default: - return -1; + case XCT_BOTH: + case XCT_UNKNOWN_BO: + /* These negate each other. */ + return 0; + case XCT_OPENING: + case XCT_UNKNOWN_OP: + ++(*depth); + return 0; + case XCT_CLOSING: + case XCT_UNKNOWN_CL: + if (--(*depth) == 0) return (tcv == XCT_CLOSING) ? 2 : 1; + return 0; + default: + return -1; } } diff --git a/src/core/libs/supl/asn-rrlp/xer_decoder.h b/src/core/libs/supl/asn-rrlp/xer_decoder.h index 7ea7e5570..37d97dfaf 100644 --- a/src/core/libs/supl/asn-rrlp/xer_decoder.h +++ b/src/core/libs/supl/asn-rrlp/xer_decoder.h @@ -51,10 +51,10 @@ extern "C" const char *xml_tag, /* Expected XML tag name */ const void *buf_ptr, size_t size, int (*opt_unexpected_tag_decoder)(void *struct_key, - const void *chunk_buf, - size_t chunk_size), + const void *chunk_buf, + size_t chunk_size), ssize_t (*body_receiver)(void *struct_key, const void *chunk_buf, - size_t chunk_size, int have_more)); + size_t chunk_size, int have_more)); /* * Fetch the next XER (XML) token from the stream. @@ -69,7 +69,7 @@ extern "C" PXER_COMMENT /* A comment, may be part of */ } pxer_chunk_type_e; ssize_t xer_next_token(int *stateContext, const void *buffer, size_t size, - pxer_chunk_type_e *_ch_type); + pxer_chunk_type_e *_ch_type); /* * This function checks the buffer against the tag name is expected to @@ -87,7 +87,7 @@ extern "C" XCT_UNKNOWN_BO = 7 /* Unexpected tag */ } xer_check_tag_e; xer_check_tag_e xer_check_tag(const void *buf_ptr, int size, - const char *need_tag); + const char *need_tag); /* * Check whether this buffer consists of entirely XER whitespace characters. diff --git a/src/core/libs/supl/asn-rrlp/xer_encoder.c b/src/core/libs/supl/asn-rrlp/xer_encoder.c index e723695ae..584fbac1a 100644 --- a/src/core/libs/supl/asn-rrlp/xer_encoder.c +++ b/src/core/libs/supl/asn-rrlp/xer_encoder.c @@ -3,15 +3,15 @@ * Redistribution and modifications are permitted subject to BSD license. */ #include -#include #include +#include /* * The XER encoder of any type. May be invoked by the application. */ asn_enc_rval_t xer_encode(asn_TYPE_descriptor_t *td, void *sptr, - enum xer_encoder_flags_e xer_flags, - asn_app_consume_bytes_f *cb, void *app_key) + enum xer_encoder_flags_e xer_flags, + asn_app_consume_bytes_f *cb, void *app_key) { asn_enc_rval_t er; asn_enc_rval_t tmper; diff --git a/src/core/libs/supl/asn-rrlp/xer_encoder.h b/src/core/libs/supl/asn-rrlp/xer_encoder.h index e39f0740e..675fa7530 100644 --- a/src/core/libs/supl/asn-rrlp/xer_encoder.h +++ b/src/core/libs/supl/asn-rrlp/xer_encoder.h @@ -27,10 +27,10 @@ extern "C" * The XER encoder of any type. May be invoked by the application. */ asn_enc_rval_t xer_encode(struct asn_TYPE_descriptor_s *type_descriptor, - void *struct_ptr, /* Structure to be encoded */ - enum xer_encoder_flags_e xer_flags, - asn_app_consume_bytes_f *consume_bytes_cb, - void *app_key /* Arbitrary callback argument */ + void *struct_ptr, /* Structure to be encoded */ + enum xer_encoder_flags_e xer_flags, + asn_app_consume_bytes_f *consume_bytes_cb, + void *app_key /* Arbitrary callback argument */ ); /* @@ -52,7 +52,7 @@ extern "C" int ilevel, /* Level of indentation */ enum xer_encoder_flags_e xer_flags, asn_app_consume_bytes_f *consume_bytes_cb, /* Callback */ - void *app_key /* Arbitrary callback argument */ + void *app_key /* Arbitrary callback argument */ ); #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-rrlp/xer_support.c b/src/core/libs/supl/asn-rrlp/xer_support.c index fca8b4fac..1edf24f11 100644 --- a/src/core/libs/supl/asn-rrlp/xer_support.c +++ b/src/core/libs/supl/asn-rrlp/xer_support.c @@ -24,7 +24,11 @@ typedef enum } pstate_e; static pxml_chunk_type_e final_chunk_type[] = { - PXML_TEXT, PXML_TAG_END, PXML_COMMENT_END, PXML_TAG_END, PXML_COMMENT_END, + PXML_TEXT, + PXML_TAG_END, + PXML_COMMENT_END, + PXML_TAG_END, + PXML_COMMENT_END, }; static int _charclass[256] = { @@ -32,10 +36,10 @@ static int _charclass[256] = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 0, 0, 0, 0, 0, 0, /* 01234567 89 */ - 0, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, /* ABCDEFG HIJKLMNO */ - 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0, /* PQRSTUVW XYZ */ - 0, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, /* abcdefg hijklmno */ - 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0 /* pqrstuvw xyz */ + 0, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, /* ABCDEFG HIJKLMNO */ + 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0, /* PQRSTUVW XYZ */ + 0, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, /* abcdefg hijklmno */ + 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0 /* pqrstuvw xyz */ }; #define WHITESPACE(c) (_charclass[(unsigned char)(c)] == 1) #define ALNUM(c) (_charclass[(unsigned char)(c)] >= 2) @@ -85,7 +89,7 @@ static int _charclass[256] = { * Parser itself */ ssize_t pxml_parse(int *stateContext, const void *xmlbuf, size_t size, - pxml_callback_f *cb, void *key) + pxml_callback_f *cb, void *key) { pstate_e state = (pstate_e)*stateContext; const char *chunk_start = (const char *)xmlbuf; @@ -97,142 +101,142 @@ ssize_t pxml_parse(int *stateContext, const void *xmlbuf, size_t size, int C = *(const unsigned char *)p; switch (state) { - case ST_TEXT: - /* + case ST_TEXT: + /* * Initial state: we're in the middle of some text, * or just have started. */ - if (C == LANGLE) /* We're now in the tag, probably */ - TOKEN_CB(PXML_TEXT, ST_TAG_START, 0); - break; - case ST_TAG_START: - if (ALPHA(C) || (C == CSLASH)) - state = ST_TAG_BODY; - else if (C == EXCLAM) - state = ST_COMMENT_WAIT_DASH1; - else - /* + if (C == LANGLE) /* We're now in the tag, probably */ + TOKEN_CB(PXML_TEXT, ST_TAG_START, 0); + break; + case ST_TAG_START: + if (ALPHA(C) || (C == CSLASH)) + state = ST_TAG_BODY; + else if (C == EXCLAM) + state = ST_COMMENT_WAIT_DASH1; + else + /* * Not characters and not whitespace. * Must be something like "3 < 4". */ - TOKEN_CB(PXML_TEXT, ST_TEXT, 1); /* Flush as data */ - break; - case ST_TAG_BODY: - switch (C) - { - case RANGLE: - /* End of the tag */ - TOKEN_CB_FINAL(PXML_TAG, ST_TEXT, 1); - break; - case LANGLE: - /* + TOKEN_CB(PXML_TEXT, ST_TEXT, 1); /* Flush as data */ + break; + case ST_TAG_BODY: + switch (C) + { + case RANGLE: + /* End of the tag */ + TOKEN_CB_FINAL(PXML_TAG, ST_TEXT, 1); + break; + case LANGLE: + /* * The previous tag wasn't completed, but * still recognized as valid. * (Mozilla-compatible) */ - TOKEN_CB_FINAL(PXML_TAG, ST_TAG_START, 0); - break; - case CEQUAL: - state = ST_TAG_QUOTE_WAIT; - break; - } - break; - case ST_TAG_QUOTE_WAIT: - /* + TOKEN_CB_FINAL(PXML_TAG, ST_TAG_START, 0); + break; + case CEQUAL: + state = ST_TAG_QUOTE_WAIT; + break; + } + break; + case ST_TAG_QUOTE_WAIT: + /* * State after the equal sign ("=") in the tag. */ - switch (C) - { - case CQUOTE: - state = ST_TAG_QUOTED_STRING; - break; - case RANGLE: - /* End of the tag */ - TOKEN_CB_FINAL(PXML_TAG, ST_TEXT, 1); - break; - default: - if (!WHITESPACE( - C)) /* Unquoted string value */ - state = ST_TAG_UNQUOTED_STRING; - } - break; - case ST_TAG_QUOTED_STRING: - /* + switch (C) + { + case CQUOTE: + state = ST_TAG_QUOTED_STRING; + break; + case RANGLE: + /* End of the tag */ + TOKEN_CB_FINAL(PXML_TAG, ST_TEXT, 1); + break; + default: + if (!WHITESPACE( + C)) /* Unquoted string value */ + state = ST_TAG_UNQUOTED_STRING; + } + break; + case ST_TAG_QUOTED_STRING: + /* * Tag attribute's string value in quotes. */ - if (C == CQUOTE) - { - /* Return back to the tag state */ - state = ST_TAG_BODY; - } - break; - case ST_TAG_UNQUOTED_STRING: - if (C == RANGLE) - { - /* End of the tag */ - TOKEN_CB_FINAL(PXML_TAG, ST_TEXT, 1); - } - else if (WHITESPACE(C)) - { - /* Return back to the tag state */ - state = ST_TAG_BODY; - } - break; - case ST_COMMENT_WAIT_DASH1: - if (C == CDASH) - { - state = ST_COMMENT_WAIT_DASH2; - } - else - { - /* Some ordinary tag. */ - state = ST_TAG_BODY; - } - break; - case ST_COMMENT_WAIT_DASH2: - if (C == CDASH) - { - /* Seen "<--" */ - state = ST_COMMENT; - } - else - { - /* Some ordinary tag */ - state = ST_TAG_BODY; - } - break; - case ST_COMMENT: - if (C == CDASH) - { - state = ST_COMMENT_CLO_DASH2; - } - break; - case ST_COMMENT_CLO_DASH2: - if (C == CDASH) - { - state = ST_COMMENT_CLO_RT; - } - else - { - /* This is not an end of a comment */ - state = ST_COMMENT; - } - break; - case ST_COMMENT_CLO_RT: - if (C == RANGLE) - { - TOKEN_CB_FINAL(PXML_COMMENT, ST_TEXT, 1); - } - else if (C == CDASH) - { - /* Maintain current state, still waiting for '>' + if (C == CQUOTE) + { + /* Return back to the tag state */ + state = ST_TAG_BODY; + } + break; + case ST_TAG_UNQUOTED_STRING: + if (C == RANGLE) + { + /* End of the tag */ + TOKEN_CB_FINAL(PXML_TAG, ST_TEXT, 1); + } + else if (WHITESPACE(C)) + { + /* Return back to the tag state */ + state = ST_TAG_BODY; + } + break; + case ST_COMMENT_WAIT_DASH1: + if (C == CDASH) + { + state = ST_COMMENT_WAIT_DASH2; + } + else + { + /* Some ordinary tag. */ + state = ST_TAG_BODY; + } + break; + case ST_COMMENT_WAIT_DASH2: + if (C == CDASH) + { + /* Seen "<--" */ + state = ST_COMMENT; + } + else + { + /* Some ordinary tag */ + state = ST_TAG_BODY; + } + break; + case ST_COMMENT: + if (C == CDASH) + { + state = ST_COMMENT_CLO_DASH2; + } + break; + case ST_COMMENT_CLO_DASH2: + if (C == CDASH) + { + state = ST_COMMENT_CLO_RT; + } + else + { + /* This is not an end of a comment */ + state = ST_COMMENT; + } + break; + case ST_COMMENT_CLO_RT: + if (C == RANGLE) + { + TOKEN_CB_FINAL(PXML_COMMENT, ST_TEXT, 1); + } + else if (C == CDASH) + { + /* Maintain current state, still waiting for '>' */ - } - else - { - state = ST_COMMENT; - } - break; + } + else + { + state = ST_COMMENT; + } + break; } /* switch(*ptr) */ } /* for() */ @@ -243,14 +247,14 @@ ssize_t pxml_parse(int *stateContext, const void *xmlbuf, size_t size, { switch (state) { - case ST_COMMENT: - TOKEN_CB(PXML_COMMENT, state, 0); - break; - case ST_TEXT: - TOKEN_CB(PXML_TEXT, state, 0); - break; - default: - break; /* a no-op */ + case ST_COMMENT: + TOKEN_CB(PXML_COMMENT, state, 0); + break; + case ST_TEXT: + TOKEN_CB(PXML_TEXT, state, 0); + break; + default: + break; /* a no-op */ } } diff --git a/src/core/libs/supl/asn-rrlp/xer_support.h b/src/core/libs/supl/asn-rrlp/xer_support.h index 927092c01..607185e1e 100644 --- a/src/core/libs/supl/asn-rrlp/xer_support.h +++ b/src/core/libs/supl/asn-rrlp/xer_support.h @@ -38,8 +38,8 @@ extern "C" * The chunk is NOT '\0'-terminated. */ typedef int(pxml_callback_f)(pxml_chunk_type_e _type, - const void *_chunk_data, size_t _chunk_size, - void *_key); + const void *_chunk_data, size_t _chunk_size, + void *_key); /* * Parse the given buffer as it were a chunk of XML data. @@ -49,7 +49,7 @@ extern "C" * The next invocation of this function must account the difference. */ ssize_t pxml_parse(int *_stateContext, const void *_buf, size_t _size, - pxml_callback_f *cb, void *_key); + pxml_callback_f *cb, void *_key); #ifdef __cplusplus } diff --git a/src/core/libs/supl/asn-supl/.clang-format b/src/core/libs/supl/asn-supl/.clang-format deleted file mode 100644 index 15e78fedf..000000000 --- a/src/core/libs/supl/asn-supl/.clang-format +++ /dev/null @@ -1,5 +0,0 @@ ---- -Language: Cpp -DisableFormat: true -... - diff --git a/src/core/libs/supl/asn-supl/AltitudeInfo.c b/src/core/libs/supl/asn-supl/AltitudeInfo.c index 0da8ee698..ea1c7a15c 100644 --- a/src/core/libs/supl/asn-supl/AltitudeInfo.c +++ b/src/core/libs/supl/asn-supl/AltitudeInfo.c @@ -7,9 +7,9 @@ #include "AltitudeInfo.h" static int altitudeDirection_2_constraint(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { /* Replace with underlying type checker */ td->check_constraints = asn_DEF_ENUMERATED.check_constraints; @@ -41,15 +41,15 @@ static void altitudeDirection_2_inherit_TYPE_descriptor( } static void altitudeDirection_2_free(asn_TYPE_descriptor_t *td, - void *struct_ptr, int contents_only) + void *struct_ptr, int contents_only) { altitudeDirection_2_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } static int altitudeDirection_2_print(asn_TYPE_descriptor_t *td, - const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + const void *struct_ptr, int ilevel, + asn_app_consume_bytes_f *cb, void *app_key) { altitudeDirection_2_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); @@ -61,7 +61,7 @@ static asn_dec_rval_t altitudeDirection_2_decode_ber( { altitudeDirection_2_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } static asn_enc_rval_t altitudeDirection_2_encode_der( @@ -78,7 +78,7 @@ static asn_dec_rval_t altitudeDirection_2_decode_xer( { altitudeDirection_2_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } static asn_enc_rval_t altitudeDirection_2_encode_xer( @@ -96,7 +96,7 @@ static asn_dec_rval_t altitudeDirection_2_decode_uper( { altitudeDirection_2_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } static asn_enc_rval_t altitudeDirection_2_encode_uper( @@ -108,16 +108,16 @@ static asn_enc_rval_t altitudeDirection_2_encode_uper( } static int memb_altitude_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -131,7 +131,7 @@ static int memb_altitude_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -145,7 +145,7 @@ static int memb_altUncertainty_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -159,7 +159,7 @@ static int memb_altUncertainty_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -227,19 +227,19 @@ static /* Use -fall-defs-global to expose */ static asn_TYPE_member_t asn_MBR_AltitudeInfo_1[] = { {ATF_NOFLAGS, 0, offsetof(struct AltitudeInfo, altitudeDirection), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_altitudeDirection_2, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "altitudeDirection"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_altitudeDirection_2, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "altitudeDirection"}, {ATF_NOFLAGS, 0, offsetof(struct AltitudeInfo, altitude), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_altitude_constraint_1, - &ASN_PER_MEMB_ALTITUDE_CONSTR_5, 0, "altitude"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_altitude_constraint_1, + &ASN_PER_MEMB_ALTITUDE_CONSTR_5, 0, "altitude"}, {ATF_NOFLAGS, 0, offsetof(struct AltitudeInfo, altUncertainty), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_altUncertainty_constraint_1, - &ASN_PER_MEMB_ALT_UNCERTAINTY_CONSTR_6, 0, "altUncertainty"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_altUncertainty_constraint_1, + &ASN_PER_MEMB_ALT_UNCERTAINTY_CONSTR_6, 0, "altUncertainty"}, }; static ber_tlv_tag_t asn_DEF_AltitudeInfo_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-supl/BIT_STRING.c b/src/core/libs/supl/asn-supl/BIT_STRING.c index 8439afc33..6e958c1bf 100644 --- a/src/core/libs/supl/asn-supl/BIT_STRING.c +++ b/src/core/libs/supl/asn-supl/BIT_STRING.c @@ -2,7 +2,6 @@ * Copyright (c) 2003, 2004 Lev Walkin . All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ -#include #include #include @@ -39,7 +38,7 @@ asn_TYPE_descriptor_t asn_DEF_BIT_STRING = { * BIT STRING generic constraint. */ int BIT_STRING_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { const BIT_STRING_t *st = (const BIT_STRING_t *)sptr; @@ -49,15 +48,15 @@ int BIT_STRING_constraint(asn_TYPE_descriptor_t *td, const void *sptr, st->bits_unused > 7) { _ASN_CTFAIL(app_key, td, sptr, - "%s: invalid padding byte (%s:%d)", td->name, - __FILE__, __LINE__); + "%s: invalid padding byte (%s:%d)", td->name, + __FILE__, __LINE__); return -1; } } else { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -65,12 +64,12 @@ int BIT_STRING_constraint(asn_TYPE_descriptor_t *td, const void *sptr, } static char *_bit_pattern[16] = {"0000", "0001", "0010", "0011", "0100", "0101", - "0110", "0111", "1000", "1001", "1010", "1011", - "1100", "1101", "1110", "1111"}; + "0110", "0111", "1000", "1001", "1010", "1011", + "1100", "1101", "1110", "1111"}; asn_enc_rval_t BIT_STRING_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { asn_enc_rval_t er; char scratch[128]; @@ -133,7 +132,7 @@ cb_failed: * BIT STRING specific contents printer. */ int BIT_STRING_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { static const char *h2c = "0123456789ABCDEF"; char scratch[64]; diff --git a/src/core/libs/supl/asn-supl/BOOLEAN.c b/src/core/libs/supl/asn-supl/BOOLEAN.c index 985f2638e..57ae3ac29 100644 --- a/src/core/libs/supl/asn-supl/BOOLEAN.c +++ b/src/core/libs/supl/asn-supl/BOOLEAN.c @@ -2,9 +2,9 @@ * Copyright (c) 2003, 2005 Lev Walkin . All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ -#include -#include #include +#include +#include /* * BOOLEAN basic type description. @@ -38,9 +38,9 @@ asn_TYPE_descriptor_t asn_DEF_BOOLEAN = { * Decode BOOLEAN type. */ asn_dec_rval_t BOOLEAN_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **bool_value, - const void *buf_ptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, void **bool_value, + const void *buf_ptr, size_t size, + int tag_mode) { BOOLEAN_t *st = (BOOLEAN_t *)*bool_value; asn_dec_rval_t rval; @@ -64,7 +64,7 @@ asn_dec_rval_t BOOLEAN_decode_ber(asn_codec_ctx_t *opt_codec_ctx, * Check tags. */ rval = ber_check_tags(opt_codec_ctx, td, 0, buf_ptr, size, tag_mode, 0, - &length, 0); + &length, 0); if (rval.code != RC_OK) return rval; ASN_DEBUG("Boolean length is %d bytes", (int)length); @@ -95,14 +95,14 @@ asn_dec_rval_t BOOLEAN_decode_ber(asn_codec_ctx_t *opt_codec_ctx, rval.consumed += length; ASN_DEBUG("Took %ld/%ld bytes to encode %s, value=%d", (long)rval.consumed, - (long)length, td->name, *st); + (long)length, td->name, *st); return rval; } asn_enc_rval_t BOOLEAN_encode_der(asn_TYPE_descriptor_t *td, void *sptr, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { asn_enc_rval_t erval; BOOLEAN_t *st = (BOOLEAN_t *)sptr; @@ -139,9 +139,9 @@ asn_enc_rval_t BOOLEAN_encode_der(asn_TYPE_descriptor_t *td, void *sptr, * Decode the chunk of XML text encoding INTEGER. */ static enum xer_pbd_rval BOOLEAN__xer_body_decode(asn_TYPE_descriptor_t *td, - void *sptr, - const void *chunk_buf, - size_t chunk_size) + void *sptr, + const void *chunk_buf, + size_t chunk_size) { BOOLEAN_t *st = (BOOLEAN_t *)sptr; const char *p = (const char *)chunk_buf; @@ -152,19 +152,19 @@ static enum xer_pbd_rval BOOLEAN__xer_body_decode(asn_TYPE_descriptor_t *td, { switch (xer_check_tag(chunk_buf, chunk_size, "false")) { - case XCT_BOTH: - /* "" */ - *st = 0; - break; - case XCT_UNKNOWN_BO: - if (xer_check_tag(chunk_buf, chunk_size, "true") != - XCT_BOTH) - return XPBD_BROKEN_ENCODING; - /* "" */ - *st = 1; /* Or 0xff as in DER?.. */ - break; - default: + case XCT_BOTH: + /* "" */ + *st = 0; + break; + case XCT_UNKNOWN_BO: + if (xer_check_tag(chunk_buf, chunk_size, "true") != + XCT_BOTH) return XPBD_BROKEN_ENCODING; + /* "" */ + *st = 1; /* Or 0xff as in DER?.. */ + break; + default: + return XPBD_BROKEN_ENCODING; } return XPBD_BODY_CONSUMED; } @@ -178,18 +178,18 @@ static enum xer_pbd_rval BOOLEAN__xer_body_decode(asn_TYPE_descriptor_t *td, } asn_dec_rval_t BOOLEAN_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **sptr, - const char *opt_mname, const void *buf_ptr, - size_t size) + asn_TYPE_descriptor_t *td, void **sptr, + const char *opt_mname, const void *buf_ptr, + size_t size) { return xer_decode_primitive(opt_codec_ctx, td, sptr, sizeof(BOOLEAN_t), - opt_mname, buf_ptr, size, - BOOLEAN__xer_body_decode); + opt_mname, buf_ptr, size, + BOOLEAN__xer_body_decode); } asn_enc_rval_t BOOLEAN_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { const BOOLEAN_t *st = (const BOOLEAN_t *)sptr; asn_enc_rval_t er; @@ -216,7 +216,7 @@ cb_failed: } int BOOLEAN_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { const BOOLEAN_t *st = (const BOOLEAN_t *)sptr; const char *buf; @@ -256,9 +256,9 @@ void BOOLEAN_free(asn_TYPE_descriptor_t *td, void *ptr, int contents_only) } asn_dec_rval_t BOOLEAN_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd) { asn_dec_rval_t rv; BOOLEAN_t *st = (BOOLEAN_t *)*sptr; @@ -277,15 +277,15 @@ asn_dec_rval_t BOOLEAN_decode_uper(asn_codec_ctx_t *opt_codec_ctx, */ switch (per_get_few_bits(pd, 1)) { - case 1: - *st = 1; - break; - case 0: - *st = 0; - break; - case -1: - default: - _ASN_DECODE_STARVED; + case 1: + *st = 1; + break; + case 0: + *st = 0; + break; + case -1: + default: + _ASN_DECODE_STARVED; } ASN_DEBUG("%s decoded as %s", td->name, *st ? "TRUE" : "FALSE"); @@ -296,8 +296,8 @@ asn_dec_rval_t BOOLEAN_decode_uper(asn_codec_ctx_t *opt_codec_ctx, } asn_enc_rval_t BOOLEAN_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *sptr, asn_per_outp_t *po) + asn_per_constraints_t *constraints, + void *sptr, asn_per_outp_t *po) { const BOOLEAN_t *st = (const BOOLEAN_t *)sptr; asn_enc_rval_t er; diff --git a/src/core/libs/supl/asn-supl/CPICH-Ec-N0.c b/src/core/libs/supl/asn-supl/CPICH-Ec-N0.c index 59325b204..e121f18f7 100644 --- a/src/core/libs/supl/asn-supl/CPICH-Ec-N0.c +++ b/src/core/libs/supl/asn-supl/CPICH-Ec-N0.c @@ -7,14 +7,14 @@ #include "CPICH-Ec-N0.h" int CPICH_Ec_N0_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int CPICH_Ec_N0_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -55,73 +55,73 @@ static void CPICH_Ec_N0_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void CPICH_Ec_N0_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { CPICH_Ec_N0_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int CPICH_Ec_N0_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { CPICH_Ec_N0_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t CPICH_Ec_N0_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { CPICH_Ec_N0_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t CPICH_Ec_N0_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { CPICH_Ec_N0_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t CPICH_Ec_N0_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, const char *opt_mname, + const void *bufptr, size_t size) { CPICH_Ec_N0_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t CPICH_Ec_N0_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { CPICH_Ec_N0_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t CPICH_Ec_N0_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { CPICH_Ec_N0_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t CPICH_Ec_N0_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { CPICH_Ec_N0_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-supl/CPICH-RSCP.c b/src/core/libs/supl/asn-supl/CPICH-RSCP.c index b91af81fa..20dfe6ab8 100644 --- a/src/core/libs/supl/asn-supl/CPICH-RSCP.c +++ b/src/core/libs/supl/asn-supl/CPICH-RSCP.c @@ -7,14 +7,14 @@ #include "CPICH-RSCP.h" int CPICH_RSCP_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int CPICH_RSCP_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -55,69 +55,69 @@ static void CPICH_RSCP_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void CPICH_RSCP_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { CPICH_RSCP_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int CPICH_RSCP_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { CPICH_RSCP_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t CPICH_RSCP_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { CPICH_RSCP_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t CPICH_RSCP_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { CPICH_RSCP_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t CPICH_RSCP_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, const char *opt_mname, + const void *bufptr, size_t size) { CPICH_RSCP_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t CPICH_RSCP_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { CPICH_RSCP_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t CPICH_RSCP_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { CPICH_RSCP_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t CPICH_RSCP_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { CPICH_RSCP_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-supl/CdmaCellInformation.c b/src/core/libs/supl/asn-supl/CdmaCellInformation.c index ea6f78e86..bb6f9001b 100644 --- a/src/core/libs/supl/asn-supl/CdmaCellInformation.c +++ b/src/core/libs/supl/asn-supl/CdmaCellInformation.c @@ -7,15 +7,15 @@ #include "CdmaCellInformation.h" static int memb_refNID_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,21 +29,21 @@ static int memb_refNID_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_refSID_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -57,22 +57,22 @@ static int memb_refSID_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_refBASEID_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -86,22 +86,22 @@ static int memb_refBASEID_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_refBASELAT_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -115,22 +115,22 @@ static int memb_refBASELAT_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_reBASELONG_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -144,22 +144,22 @@ static int memb_reBASELONG_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_refREFPN_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -173,7 +173,7 @@ static int memb_refREFPN_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -187,7 +187,7 @@ static int memb_refWeekNumber_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -201,22 +201,22 @@ static int memb_refWeekNumber_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_refSeconds_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -230,7 +230,7 @@ static int memb_refSeconds_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -285,37 +285,37 @@ static asn_per_constraints_t ASN_PER_MEMB_REF_SECONDS_CONSTR_9 = { }; static asn_TYPE_member_t asn_MBR_CdmaCellInformation_1[] = { {ATF_NOFLAGS, 0, offsetof(struct CdmaCellInformation, refNID), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_refNID_constraint_1, - &ASN_PER_MEMB_REF_NID_CONSTR_2, 0, "refNID"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_refNID_constraint_1, + &ASN_PER_MEMB_REF_NID_CONSTR_2, 0, "refNID"}, {ATF_NOFLAGS, 0, offsetof(struct CdmaCellInformation, refSID), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_refSID_constraint_1, - &ASN_PER_MEMB_REF_SID_CONSTR_3, 0, "refSID"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_refSID_constraint_1, + &ASN_PER_MEMB_REF_SID_CONSTR_3, 0, "refSID"}, {ATF_NOFLAGS, 0, offsetof(struct CdmaCellInformation, refBASEID), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_refBASEID_constraint_1, - &ASN_PER_MEMB_REF_BASEID_CONSTR_4, 0, "refBASEID"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_refBASEID_constraint_1, + &ASN_PER_MEMB_REF_BASEID_CONSTR_4, 0, "refBASEID"}, {ATF_NOFLAGS, 0, offsetof(struct CdmaCellInformation, refBASELAT), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_refBASELAT_constraint_1, - &ASN_PER_MEMB_REF_BASELAT_CONSTR_5, 0, "refBASELAT"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_refBASELAT_constraint_1, + &ASN_PER_MEMB_REF_BASELAT_CONSTR_5, 0, "refBASELAT"}, {ATF_NOFLAGS, 0, offsetof(struct CdmaCellInformation, reBASELONG), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_reBASELONG_constraint_1, - &ASN_PER_MEMB_RE_BASELONG_CONSTR_6, 0, "reBASELONG"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_reBASELONG_constraint_1, + &ASN_PER_MEMB_RE_BASELONG_CONSTR_6, 0, "reBASELONG"}, {ATF_NOFLAGS, 0, offsetof(struct CdmaCellInformation, refREFPN), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_refREFPN_constraint_1, - &ASN_PER_MEMB_REF_REFPN_CONSTR_7, 0, "refREFPN"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_refREFPN_constraint_1, + &ASN_PER_MEMB_REF_REFPN_CONSTR_7, 0, "refREFPN"}, {ATF_NOFLAGS, 0, offsetof(struct CdmaCellInformation, refWeekNumber), - (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_refWeekNumber_constraint_1, - &ASN_PER_MEMB_REF_WEEK_NUMBER_CONSTR_8, 0, "refWeekNumber"}, + (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_refWeekNumber_constraint_1, + &ASN_PER_MEMB_REF_WEEK_NUMBER_CONSTR_8, 0, "refWeekNumber"}, {ATF_NOFLAGS, 0, offsetof(struct CdmaCellInformation, refSeconds), - (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_refSeconds_constraint_1, - &ASN_PER_MEMB_REF_SECONDS_CONSTR_9, 0, "refSeconds"}, + (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_refSeconds_constraint_1, + &ASN_PER_MEMB_REF_SECONDS_CONSTR_9, 0, "refSeconds"}, }; static ber_tlv_tag_t asn_DEF_CdmaCellInformation_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -359,7 +359,7 @@ asn_TYPE_descriptor_t asn_DEF_CdmaCellInformation = { asn_DEF_CdmaCellInformation_tags_1, /* Same as above */ sizeof(asn_DEF_CdmaCellInformation_tags_1) / sizeof(asn_DEF_CdmaCellInformation_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_CdmaCellInformation_1, 8, /* Elements count */ &asn_SPC_CdmaCellInformation_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-supl/CellInfo.c b/src/core/libs/supl/asn-supl/CellInfo.c index f8c0de7e3..05ef0be1d 100644 --- a/src/core/libs/supl/asn-supl/CellInfo.c +++ b/src/core/libs/supl/asn-supl/CellInfo.c @@ -14,23 +14,23 @@ static asn_per_constraints_t ASN_PER_TYPE_CELL_INFO_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_CellInfo_1[] = { {ATF_NOFLAGS, 0, offsetof(struct CellInfo, choice.gsmCell), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_GsmCellInformation, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "gsmCell"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_GsmCellInformation, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "gsmCell"}, {ATF_NOFLAGS, 0, offsetof(struct CellInfo, choice.wcdmaCell), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_WcdmaCellInformation, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "wcdmaCell"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_WcdmaCellInformation, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "wcdmaCell"}, {ATF_NOFLAGS, 0, offsetof(struct CellInfo, choice.cdmaCell), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_CdmaCellInformation, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "cdmaCell"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_CdmaCellInformation, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "cdmaCell"}, }; static asn_TYPE_tag2member_t asn_MAP_CellInfo_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* gsmCell at 61 */ diff --git a/src/core/libs/supl/asn-supl/CellInfo.h b/src/core/libs/supl/asn-supl/CellInfo.h index f688eb7ae..e03622365 100644 --- a/src/core/libs/supl/asn-supl/CellInfo.h +++ b/src/core/libs/supl/asn-supl/CellInfo.h @@ -10,9 +10,9 @@ #include /* Including external dependencies */ +#include "CdmaCellInformation.h" #include "GsmCellInformation.h" #include "WcdmaCellInformation.h" -#include "CdmaCellInformation.h" #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-supl/CellMeasuredResults.c b/src/core/libs/supl/asn-supl/CellMeasuredResults.c index e27f43322..38bc8377a 100644 --- a/src/core/libs/supl/asn-supl/CellMeasuredResults.c +++ b/src/core/libs/supl/asn-supl/CellMeasuredResults.c @@ -7,16 +7,16 @@ #include "CellMeasuredResults.h" static int memb_cellIdentity_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,7 +30,7 @@ static int memb_cellIdentity_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -49,34 +49,34 @@ static asn_per_constraints_t ASN_PER_MEMB_CELL_IDENTITY_CONSTR_2 = { }; static asn_TYPE_member_t asn_MBR_fdd_4[] = { {ATF_NOFLAGS, 0, offsetof(struct fdd, primaryCPICH_Info), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_PrimaryCPICH_Info, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "primaryCPICH-Info"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_PrimaryCPICH_Info, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "primaryCPICH-Info"}, {ATF_POINTER, 3, offsetof(struct fdd, cpich_Ec_N0), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_CPICH_Ec_N0, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "cpich-Ec-N0"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_CPICH_Ec_N0, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "cpich-Ec-N0"}, {ATF_POINTER, 2, offsetof(struct fdd, cpich_RSCP), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_CPICH_RSCP, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "cpich-RSCP"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_CPICH_RSCP, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "cpich-RSCP"}, {ATF_POINTER, 1, offsetof(struct fdd, pathloss), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Pathloss, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "pathloss"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Pathloss, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "pathloss"}, }; static int asn_MAP_fdd_oms_4[] = {1, 2, 3}; static ber_tlv_tag_t asn_DEF_fdd_tags_4[] = { (ASN_TAG_CLASS_CONTEXT | (0 << 2)), (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_fdd_tag2el_4[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0}, /* primaryCPICH-Info at 163 */ + 0}, /* primaryCPICH-Info at 163 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0}, /* cpich-Ec-N0 at 164 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0}, /* cpich-RSCP at 165 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, 0} /* pathloss at 166 */ @@ -108,9 +108,9 @@ static /* Use -fall-defs-global to expose */ 0, /* Use generic outmost tag fetcher */ asn_DEF_fdd_tags_4, sizeof(asn_DEF_fdd_tags_4) / sizeof(asn_DEF_fdd_tags_4[0]) - 1, /* 1 */ - asn_DEF_fdd_tags_4, /* Same as above */ - sizeof(asn_DEF_fdd_tags_4) / sizeof(asn_DEF_fdd_tags_4[0]), /* 2 */ - 0, /* No PER visible constraints */ + asn_DEF_fdd_tags_4, /* Same as above */ + sizeof(asn_DEF_fdd_tags_4) / sizeof(asn_DEF_fdd_tags_4[0]), /* 2 */ + 0, /* No PER visible constraints */ asn_MBR_fdd_4, 4, /* Elements count */ &asn_SPC_fdd_specs_4 /* Additional specs */ @@ -118,33 +118,33 @@ static /* Use -fall-defs-global to expose */ static asn_TYPE_member_t asn_MBR_tdd_9[] = { {ATF_NOFLAGS, 0, offsetof(struct tdd, cellParametersID), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_CellParametersID, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "cellParametersID"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_CellParametersID, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "cellParametersID"}, {ATF_POINTER, 4, offsetof(struct tdd, proposedTGSN), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_TGSN, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "proposedTGSN"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_TGSN, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "proposedTGSN"}, {ATF_POINTER, 3, offsetof(struct tdd, primaryCCPCH_RSCP), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_PrimaryCCPCH_RSCP, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "primaryCCPCH-RSCP"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_PrimaryCCPCH_RSCP, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "primaryCCPCH-RSCP"}, {ATF_POINTER, 2, offsetof(struct tdd, pathloss), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Pathloss, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "pathloss"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Pathloss, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "pathloss"}, {ATF_POINTER, 1, offsetof(struct tdd, timeslotISCP_List), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_TimeslotISCP_List, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "timeslotISCP-List"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_TimeslotISCP_List, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "timeslotISCP-List"}, }; static int asn_MAP_tdd_oms_9[] = {1, 2, 3, 4}; static ber_tlv_tag_t asn_DEF_tdd_tags_9[] = { @@ -153,9 +153,9 @@ static asn_TYPE_tag2member_t asn_MAP_tdd_tag2el_9[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* cellParametersID at 168 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0}, /* proposedTGSN at 169 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, - 0}, /* primaryCCPCH-RSCP at 170 */ + 0}, /* primaryCCPCH-RSCP at 170 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, 0}, /* pathloss at 171 */ - {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, 0} /* timeslotISCP-List at 172 */ + {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, 0} /* timeslotISCP-List at 172 */ }; static asn_SEQUENCE_specifics_t asn_SPC_tdd_specs_9 = { sizeof(struct tdd), @@ -184,9 +184,9 @@ static /* Use -fall-defs-global to expose */ 0, /* Use generic outmost tag fetcher */ asn_DEF_tdd_tags_9, sizeof(asn_DEF_tdd_tags_9) / sizeof(asn_DEF_tdd_tags_9[0]) - 1, /* 1 */ - asn_DEF_tdd_tags_9, /* Same as above */ - sizeof(asn_DEF_tdd_tags_9) / sizeof(asn_DEF_tdd_tags_9[0]), /* 2 */ - 0, /* No PER visible constraints */ + asn_DEF_tdd_tags_9, /* Same as above */ + sizeof(asn_DEF_tdd_tags_9) / sizeof(asn_DEF_tdd_tags_9[0]), /* 2 */ + 0, /* No PER visible constraints */ asn_MBR_tdd_9, 5, /* Elements count */ &asn_SPC_tdd_specs_9 /* Additional specs */ @@ -194,15 +194,15 @@ static /* Use -fall-defs-global to expose */ static asn_TYPE_member_t asn_MBR_modeSpecificInfo_3[] = { {ATF_NOFLAGS, 0, offsetof(struct modeSpecificInfo, choice.fdd), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, &asn_DEF_fdd_4, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "fdd"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, &asn_DEF_fdd_4, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "fdd"}, {ATF_NOFLAGS, 0, offsetof(struct modeSpecificInfo, choice.tdd), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 0, &asn_DEF_tdd_9, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "tdd"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 0, &asn_DEF_tdd_9, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "tdd"}, }; static asn_TYPE_tag2member_t asn_MAP_modeSpecificInfo_tag2el_3[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* fdd at 163 */ @@ -244,15 +244,15 @@ static /* Use -fall-defs-global to expose */ static asn_TYPE_member_t asn_MBR_CellMeasuredResults_1[] = { {ATF_POINTER, 1, offsetof(struct CellMeasuredResults, cellIdentity), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_cellIdentity_constraint_1, - &ASN_PER_MEMB_CELL_IDENTITY_CONSTR_2, 0, "cellIdentity"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_cellIdentity_constraint_1, + &ASN_PER_MEMB_CELL_IDENTITY_CONSTR_2, 0, "cellIdentity"}, {ATF_NOFLAGS, 0, offsetof(struct CellMeasuredResults, modeSpecificInfo), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), +1, /* EXPLICIT tag at current level */ - &asn_DEF_modeSpecificInfo_3, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "modeSpecificInfo"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), +1, /* EXPLICIT tag at current level */ + &asn_DEF_modeSpecificInfo_3, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "modeSpecificInfo"}, }; static int asn_MAP_CellMeasuredResults_oms_1[] = {0}; static ber_tlv_tag_t asn_DEF_CellMeasuredResults_tags_1[] = { @@ -291,7 +291,7 @@ asn_TYPE_descriptor_t asn_DEF_CellMeasuredResults = { asn_DEF_CellMeasuredResults_tags_1, /* Same as above */ sizeof(asn_DEF_CellMeasuredResults_tags_1) / sizeof(asn_DEF_CellMeasuredResults_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_CellMeasuredResults_1, 2, /* Elements count */ &asn_SPC_CellMeasuredResults_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-supl/CellMeasuredResults.h b/src/core/libs/supl/asn-supl/CellMeasuredResults.h index 62c0be629..a1d9ffdce 100644 --- a/src/core/libs/supl/asn-supl/CellMeasuredResults.h +++ b/src/core/libs/supl/asn-supl/CellMeasuredResults.h @@ -10,16 +10,16 @@ #include /* Including external dependencies */ -#include -#include "PrimaryCPICH-Info.h" #include "CPICH-Ec-N0.h" #include "CPICH-RSCP.h" -#include "Pathloss.h" -#include #include "CellParametersID.h" -#include "TGSN.h" +#include "Pathloss.h" #include "PrimaryCCPCH-RSCP.h" +#include "PrimaryCPICH-Info.h" +#include "TGSN.h" +#include #include +#include #ifdef __cplusplus extern "C" diff --git a/src/core/libs/supl/asn-supl/CellMeasuredResultsList.c b/src/core/libs/supl/asn-supl/CellMeasuredResultsList.c index 21cd4707e..8e13034f2 100644 --- a/src/core/libs/supl/asn-supl/CellMeasuredResultsList.c +++ b/src/core/libs/supl/asn-supl/CellMeasuredResultsList.c @@ -15,10 +15,10 @@ static asn_per_constraints_t ASN_PER_TYPE_CELL_MEASURED_RESULTS_LIST_CONSTR_1 = }; static asn_TYPE_member_t asn_MBR_CellMeasuredResultsList_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_CellMeasuredResults, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_CellMeasuredResults, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_CellMeasuredResultsList_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-supl/CellParametersID.c b/src/core/libs/supl/asn-supl/CellParametersID.c index b5944f61a..ff3d291d7 100644 --- a/src/core/libs/supl/asn-supl/CellParametersID.c +++ b/src/core/libs/supl/asn-supl/CellParametersID.c @@ -7,15 +7,15 @@ #include "CellParametersID.h" int CellParametersID_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ int CellParametersID_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -57,76 +57,76 @@ static void CellParametersID_1_inherit_TYPE_descriptor( } void CellParametersID_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { CellParametersID_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int CellParametersID_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, + void *app_key) { CellParametersID_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t CellParametersID_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { CellParametersID_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t CellParametersID_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { CellParametersID_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t CellParametersID_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { CellParametersID_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t CellParametersID_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { CellParametersID_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t CellParametersID_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { CellParametersID_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t CellParametersID_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { CellParametersID_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-supl/DUMMY.c b/src/core/libs/supl/asn-supl/DUMMY.c index fcc981928..313c5ed82 100644 --- a/src/core/libs/supl/asn-supl/DUMMY.c +++ b/src/core/libs/supl/asn-supl/DUMMY.c @@ -7,7 +7,7 @@ #include "DUMMY.h" int DUMMY_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { /* Replace with underlying type checker */ td->check_constraints = asn_DEF_INTEGER.check_constraints; @@ -42,60 +42,60 @@ void DUMMY_free(asn_TYPE_descriptor_t *td, void *struct_ptr, int contents_only) } int DUMMY_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { DUMMY_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t DUMMY_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, int tag_mode) { DUMMY_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t DUMMY_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { DUMMY_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t DUMMY_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { DUMMY_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t DUMMY_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { DUMMY_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t DUMMY_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { DUMMY_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t DUMMY_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { DUMMY_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); @@ -118,9 +118,9 @@ asn_TYPE_descriptor_t asn_DEF_DUMMY = { 0, /* Use generic outmost tag fetcher */ asn_DEF_DUMMY_tags_1, sizeof(asn_DEF_DUMMY_tags_1) / sizeof(asn_DEF_DUMMY_tags_1[0]), /* 1 */ - asn_DEF_DUMMY_tags_1, /* Same as above */ + asn_DEF_DUMMY_tags_1, /* Same as above */ sizeof(asn_DEF_DUMMY_tags_1) / sizeof(asn_DEF_DUMMY_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ 0, 0, /* No members */ 0 /* No specifics */ diff --git a/src/core/libs/supl/asn-supl/ENUMERATED.c b/src/core/libs/supl/asn-supl/ENUMERATED.c index b41f70a42..dd0d13d9b 100644 --- a/src/core/libs/supl/asn-supl/ENUMERATED.c +++ b/src/core/libs/supl/asn-supl/ENUMERATED.c @@ -3,10 +3,10 @@ * All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ -#include #include #include #include /* Encoder and decoder of a primitive type */ +#include /* * ENUMERATED basic type description. @@ -37,9 +37,9 @@ asn_TYPE_descriptor_t asn_DEF_ENUMERATED = { }; asn_dec_rval_t ENUMERATED_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd) { asn_dec_rval_t rval; ENUMERATED_t *st = (ENUMERATED_t *)*sptr; @@ -60,8 +60,8 @@ asn_dec_rval_t ENUMERATED_decode_uper(asn_codec_ctx_t *opt_codec_ctx, } asn_enc_rval_t ENUMERATED_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *sptr, asn_per_outp_t *po) + asn_per_constraints_t *constraints, + void *sptr, asn_per_outp_t *po) { ENUMERATED_t *st = (ENUMERATED_t *)sptr; int64_t value; diff --git a/src/core/libs/supl/asn-supl/EncodingType.c b/src/core/libs/supl/asn-supl/EncodingType.c index a5f8e9bbd..1ab40a547 100644 --- a/src/core/libs/supl/asn-supl/EncodingType.c +++ b/src/core/libs/supl/asn-supl/EncodingType.c @@ -7,8 +7,8 @@ #include "EncodingType.h" int EncodingType_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { /* Replace with underlying type checker */ td->check_constraints = asn_DEF_ENUMERATED.check_constraints; @@ -39,74 +39,74 @@ static void EncodingType_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void EncodingType_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { EncodingType_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int EncodingType_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { EncodingType_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t EncodingType_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { EncodingType_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t EncodingType_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { EncodingType_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t EncodingType_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, const char *opt_mname, + const void *bufptr, size_t size) { EncodingType_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t EncodingType_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { EncodingType_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t EncodingType_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { EncodingType_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t EncodingType_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { EncodingType_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-supl/FQDN.c b/src/core/libs/supl/asn-supl/FQDN.c index 9cd5ddb73..ff18a4dfd 100644 --- a/src/core/libs/supl/asn-supl/FQDN.c +++ b/src/core/libs/supl/asn-supl/FQDN.c @@ -7,29 +7,88 @@ #include "FQDN.h" static int permitted_alphabet_table_1[256] = { - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, /* */ - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, /* */ - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 1, 2, 0, /* -. */ - 3, 4, 5, 6, 7, 8, 9, 10, - 11, 12, 0, 0, 0, 0, 0, 0, /* 0123456789 */ - 0, 13, 14, 15, 16, 17, 18, 19, + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, /* */ + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, /* */ + 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1, 2, 0, /* -. */ + 3, 4, 5, 6, 7, 8, 9, 10, + 11, 12, 0, 0, 0, 0, 0, 0, /* 0123456789 */ + 0, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, /* ABCDEFGHIJKLMNO */ 28, 29, 30, 31, 32, 33, 34, 35, - 36, 37, 38, 0, 0, 0, 0, 0, /* PQRSTUVWXYZ */ - 0, 39, 40, 41, 42, 43, 44, 45, + 36, 37, 38, 0, 0, 0, 0, 0, /* PQRSTUVWXYZ */ + 0, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, /* abcdefghijklmno */ 54, 55, 56, 57, 58, 59, 60, 61, - 62, 63, 64, 0, 0, 0, 0, 0, /* pqrstuvwxyz */ + 62, 63, 64, 0, 0, 0, 0, 0, /* pqrstuvwxyz */ }; static int permitted_alphabet_code2value_1[64] = { - 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 65, - 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, - 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 97, - 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, - 111, 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, 122, + 45, + 46, + 48, + 49, + 50, + 51, + 52, + 53, + 54, + 55, + 56, + 57, + 65, + 66, + 67, + 68, + 69, + 70, + 71, + 72, + 73, + 74, + 75, + 76, + 77, + 78, + 79, + 80, + 81, + 82, + 83, + 84, + 85, + 86, + 87, + 88, + 89, + 90, + 97, + 98, + 99, + 100, + 101, + 102, + 103, + 104, + 105, + 106, + 107, + 108, + 109, + 110, + 111, + 112, + 113, + 114, + 115, + 116, + 117, + 118, + 119, + 120, + 121, + 122, }; static int check_permitted_alphabet_1(const void *sptr) @@ -49,7 +108,7 @@ static int check_permitted_alphabet_1(const void *sptr) } int FQDN_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { const VisibleString_t *st = (const VisibleString_t *)sptr; size_t size; @@ -57,7 +116,7 @@ int FQDN_constraint(asn_TYPE_descriptor_t *td, const void *sptr, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -71,7 +130,7 @@ int FQDN_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -118,60 +177,60 @@ void FQDN_free(asn_TYPE_descriptor_t *td, void *struct_ptr, int contents_only) } int FQDN_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { FQDN_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t FQDN_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, int tag_mode) { FQDN_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t FQDN_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { FQDN_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t FQDN_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { FQDN_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t FQDN_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { FQDN_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t FQDN_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { FQDN_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t FQDN_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { FQDN_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); @@ -200,7 +259,7 @@ asn_TYPE_descriptor_t asn_DEF_FQDN = { 0, /* Use generic outmost tag fetcher */ asn_DEF_FQDN_tags_1, sizeof(asn_DEF_FQDN_tags_1) / sizeof(asn_DEF_FQDN_tags_1[0]), /* 1 */ - asn_DEF_FQDN_tags_1, /* Same as above */ + asn_DEF_FQDN_tags_1, /* Same as above */ sizeof(asn_DEF_FQDN_tags_1) / sizeof(asn_DEF_FQDN_tags_1[0]), /* 1 */ &ASN_PER_TYPE_FQDN_CONSTR_1, 0, diff --git a/src/core/libs/supl/asn-supl/FormatIndicator.c b/src/core/libs/supl/asn-supl/FormatIndicator.c index 737637e21..276be3210 100644 --- a/src/core/libs/supl/asn-supl/FormatIndicator.c +++ b/src/core/libs/supl/asn-supl/FormatIndicator.c @@ -7,8 +7,8 @@ #include "FormatIndicator.h" int FormatIndicator_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { /* Replace with underlying type checker */ td->check_constraints = asn_DEF_ENUMERATED.check_constraints; @@ -39,76 +39,76 @@ static void FormatIndicator_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void FormatIndicator_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { FormatIndicator_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int FormatIndicator_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, + void *app_key) { FormatIndicator_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t FormatIndicator_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { FormatIndicator_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t FormatIndicator_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { FormatIndicator_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t FormatIndicator_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { FormatIndicator_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t FormatIndicator_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { FormatIndicator_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t FormatIndicator_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { FormatIndicator_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t FormatIndicator_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { FormatIndicator_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-supl/FrequencyInfo.c b/src/core/libs/supl/asn-supl/FrequencyInfo.c index f23e82b6c..9da158506 100644 --- a/src/core/libs/supl/asn-supl/FrequencyInfo.c +++ b/src/core/libs/supl/asn-supl/FrequencyInfo.c @@ -14,17 +14,17 @@ static asn_per_constraints_t ASN_PER_TYPE_FMODE_SPECIFIC_INFO_CONSTR_2 = { }; static asn_TYPE_member_t asn_MBR_fmodeSpecificInfo_2[] = { {ATF_NOFLAGS, 0, offsetof(struct fmodeSpecificInfo, choice.fdd), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_FrequencyInfoFDD, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "fdd"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_FrequencyInfoFDD, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "fdd"}, {ATF_NOFLAGS, 0, offsetof(struct fmodeSpecificInfo, choice.tdd), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_FrequencyInfoTDD, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "tdd"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_FrequencyInfoTDD, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "tdd"}, }; static asn_TYPE_tag2member_t asn_MAP_fmodeSpecificInfo_tag2el_2[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* fdd at 122 */ @@ -66,11 +66,11 @@ static /* Use -fall-defs-global to expose */ static asn_TYPE_member_t asn_MBR_FrequencyInfo_1[] = { {ATF_NOFLAGS, 0, offsetof(struct FrequencyInfo, fmodeSpecificInfo), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), +1, /* EXPLICIT tag at current level */ - &asn_DEF_fmodeSpecificInfo_2, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "fmodeSpecificInfo"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), +1, /* EXPLICIT tag at current level */ + &asn_DEF_fmodeSpecificInfo_2, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "fmodeSpecificInfo"}, }; static ber_tlv_tag_t asn_DEF_FrequencyInfo_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -107,7 +107,7 @@ asn_TYPE_descriptor_t asn_DEF_FrequencyInfo = { asn_DEF_FrequencyInfo_tags_1, /* Same as above */ sizeof(asn_DEF_FrequencyInfo_tags_1) / sizeof(asn_DEF_FrequencyInfo_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_FrequencyInfo_1, 1, /* Elements count */ &asn_SPC_FrequencyInfo_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-supl/FrequencyInfoFDD.c b/src/core/libs/supl/asn-supl/FrequencyInfoFDD.c index c76dbcad6..bbbecd12c 100644 --- a/src/core/libs/supl/asn-supl/FrequencyInfoFDD.c +++ b/src/core/libs/supl/asn-supl/FrequencyInfoFDD.c @@ -8,15 +8,15 @@ static asn_TYPE_member_t asn_MBR_FrequencyInfoFDD_1[] = { {ATF_POINTER, 1, offsetof(struct FrequencyInfoFDD, uarfcn_UL), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_UARFCN, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "uarfcn-UL"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_UARFCN, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "uarfcn-UL"}, {ATF_NOFLAGS, 0, offsetof(struct FrequencyInfoFDD, uarfcn_DL), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_UARFCN, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "uarfcn-DL"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_UARFCN, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "uarfcn-DL"}, }; static int asn_MAP_FrequencyInfoFDD_oms_1[] = {0}; static ber_tlv_tag_t asn_DEF_FrequencyInfoFDD_tags_1[] = { @@ -55,7 +55,7 @@ asn_TYPE_descriptor_t asn_DEF_FrequencyInfoFDD = { asn_DEF_FrequencyInfoFDD_tags_1, /* Same as above */ sizeof(asn_DEF_FrequencyInfoFDD_tags_1) / sizeof(asn_DEF_FrequencyInfoFDD_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_FrequencyInfoFDD_1, 2, /* Elements count */ &asn_SPC_FrequencyInfoFDD_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-supl/FrequencyInfoTDD.c b/src/core/libs/supl/asn-supl/FrequencyInfoTDD.c index eb5eb795f..e131f79ee 100644 --- a/src/core/libs/supl/asn-supl/FrequencyInfoTDD.c +++ b/src/core/libs/supl/asn-supl/FrequencyInfoTDD.c @@ -8,10 +8,10 @@ static asn_TYPE_member_t asn_MBR_FrequencyInfoTDD_1[] = { {ATF_NOFLAGS, 0, offsetof(struct FrequencyInfoTDD, uarfcn_Nt), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_UARFCN, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "uarfcn-Nt"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_UARFCN, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "uarfcn-Nt"}, }; static ber_tlv_tag_t asn_DEF_FrequencyInfoTDD_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -48,7 +48,7 @@ asn_TYPE_descriptor_t asn_DEF_FrequencyInfoTDD = { asn_DEF_FrequencyInfoTDD_tags_1, /* Same as above */ sizeof(asn_DEF_FrequencyInfoTDD_tags_1) / sizeof(asn_DEF_FrequencyInfoTDD_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_FrequencyInfoTDD_1, 1, /* Elements count */ &asn_SPC_FrequencyInfoTDD_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-supl/GeneralizedTime.c b/src/core/libs/supl/asn-supl/GeneralizedTime.c index 0d1ab922c..60f36b6e0 100644 --- a/src/core/libs/supl/asn-supl/GeneralizedTime.c +++ b/src/core/libs/supl/asn-supl/GeneralizedTime.c @@ -6,8 +6,8 @@ #ifndef _REENTRANT #define _REENTRANT /* for Sun */ #endif -#include #include +#include #include #ifdef __CYGWIN__ @@ -209,8 +209,8 @@ asn_TYPE_descriptor_t asn_DEF_GeneralizedTime = { * Check that the time looks like the time. */ int GeneralizedTime_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const GeneralizedTime_t *st = (const GeneralizedTime_t *)sptr; time_t tloc; @@ -220,8 +220,8 @@ int GeneralizedTime_constraint(asn_TYPE_descriptor_t *td, const void *sptr, if (tloc == -1 && errno != EPERM) { _ASN_CTFAIL(app_key, td, sptr, - "%s: Invalid time format: %s (%s:%d)", td->name, - strerror(errno), __FILE__, __LINE__); + "%s: Invalid time format: %s (%s:%d)", td->name, + strerror(errno), __FILE__, __LINE__); return -1; } @@ -229,9 +229,9 @@ int GeneralizedTime_constraint(asn_TYPE_descriptor_t *td, const void *sptr, } asn_enc_rval_t GeneralizedTime_encode_der(asn_TYPE_descriptor_t *td, void *sptr, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { GeneralizedTime_t *st = (GeneralizedTime_t *)sptr; asn_enc_rval_t erval; @@ -263,10 +263,10 @@ asn_enc_rval_t GeneralizedTime_encode_der(asn_TYPE_descriptor_t *td, void *sptr, #ifndef __ASN_INTERNAL_TEST_MODE__ asn_enc_rval_t GeneralizedTime_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, - int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { if (flags & XER_F_CANONICAL) { @@ -286,22 +286,22 @@ asn_enc_rval_t GeneralizedTime_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, if (!gt) _ASN_ENCODE_FAILED; rv = OCTET_STRING_encode_xer_utf8(td, sptr, ilevel, flags, cb, - app_key); + app_key); ASN_STRUCT_FREE(asn_DEF_GeneralizedTime, gt); return rv; } else { return OCTET_STRING_encode_xer_utf8(td, sptr, ilevel, flags, cb, - app_key); + app_key); } } #endif /* __ASN_INTERNAL_TEST_MODE__ */ int GeneralizedTime_print(asn_TYPE_descriptor_t *td, const void *sptr, - int ilevel, asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, + void *app_key) { const GeneralizedTime_t *st = (const GeneralizedTime_t *)sptr; @@ -319,9 +319,9 @@ int GeneralizedTime_print(asn_TYPE_descriptor_t *td, const void *sptr, return (cb("", 11, app_key) < 0) ? -1 : 0; ret = snprintf(buf, sizeof(buf), - "%04d-%02d-%02d %02d:%02d:%02d (GMT)", - tm.tm_year + 1900, tm.tm_mon + 1, tm.tm_mday, - tm.tm_hour, tm.tm_min, tm.tm_sec); + "%04d-%02d-%02d %02d:%02d:%02d (GMT)", + tm.tm_year + 1900, tm.tm_mon + 1, tm.tm_mday, + tm.tm_hour, tm.tm_min, tm.tm_sec); assert(ret > 0 && ret < (int)sizeof(buf)); return (cb(buf, ret, app_key) < 0) ? -1 : 0; } @@ -337,7 +337,7 @@ time_t asn_GT2time(const GeneralizedTime_t *st, struct tm *ret_tm, int as_gmt) } time_t asn_GT2time_prec(const GeneralizedTime_t *st, int *frac_value, - int frac_digits, struct tm *ret_tm, int as_gmt) + int frac_digits, struct tm *ret_tm, int as_gmt) { time_t tloc; int fv; @@ -373,7 +373,7 @@ time_t asn_GT2time_prec(const GeneralizedTime_t *st, int *frac_value, } time_t asn_GT2time_frac(const GeneralizedTime_t *st, int *frac_value, - int *frac_digits, struct tm *ret_tm, int as_gmt) + int *frac_digits, struct tm *ret_tm, int as_gmt) { struct tm tm_s; uint8_t *buf; @@ -446,32 +446,32 @@ time_t asn_GT2time_frac(const GeneralizedTime_t *st, int *frac_value, */ switch (*buf) { - case 0x30: - case 0x31: - case 0x32: - case 0x33: - case 0x34: - case 0x35: - case 0x36: - case 0x37: - case 0x38: - case 0x39: - tm_s.tm_min = (*buf++) - 0x30; - if (buf == end) - { - errno = EINVAL; - return -1; - } - B2T(tm_min); - break; - case 0x2B: - case 0x2D: /* +, - */ - goto offset; - case 0x5A: /* Z */ - goto utc_finish; - default: - errno = EINVAL; - return -1; + case 0x30: + case 0x31: + case 0x32: + case 0x33: + case 0x34: + case 0x35: + case 0x36: + case 0x37: + case 0x38: + case 0x39: + tm_s.tm_min = (*buf++) - 0x30; + if (buf == end) + { + errno = EINVAL; + return -1; + } + B2T(tm_min); + break; + case 0x2B: + case 0x2D: /* +, - */ + goto offset; + case 0x5A: /* Z */ + goto utc_finish; + default: + errno = EINVAL; + return -1; } if (buf == end) goto local_finish; @@ -482,32 +482,32 @@ time_t asn_GT2time_frac(const GeneralizedTime_t *st, int *frac_value, */ switch (*buf) { - case 0x30: - case 0x31: - case 0x32: - case 0x33: - case 0x34: - case 0x35: - case 0x36: - case 0x37: - case 0x38: - case 0x39: - tm_s.tm_sec = (*buf++) - 0x30; - if (buf == end) - { - errno = EINVAL; - return -1; - } - B2T(tm_sec); - break; - case 0x2B: - case 0x2D: /* +, - */ - goto offset; - case 0x5A: /* Z */ - goto utc_finish; - default: - errno = EINVAL; - return -1; + case 0x30: + case 0x31: + case 0x32: + case 0x33: + case 0x34: + case 0x35: + case 0x36: + case 0x37: + case 0x38: + case 0x39: + tm_s.tm_sec = (*buf++) - 0x30; + if (buf == end) + { + errno = EINVAL; + return -1; + } + B2T(tm_sec); + break; + case 0x2B: + case 0x2D: /* +, - */ + goto offset; + case 0x5A: /* Z */ + goto utc_finish; + default: + errno = EINVAL; + return -1; } if (buf == end) goto local_finish; @@ -518,57 +518,57 @@ time_t asn_GT2time_frac(const GeneralizedTime_t *st, int *frac_value, */ switch (*buf) { - case 0x2C: - case 0x2E: /* (.|,) */ - /* + case 0x2C: + case 0x2E: /* (.|,) */ + /* * Process fractions of seconds. */ - for (buf++; buf < end; buf++) - { - int v = *buf; - int new_fvalue; - switch (v) - { - case 0x30: - case 0x31: - case 0x32: - case 0x33: - case 0x34: - case 0x35: - case 0x36: - case 0x37: - case 0x38: - case 0x39: - new_fvalue = fvalue * 10 + (v - 0x30); - if (new_fvalue / 10 != fvalue) - { - /* Not enough precision, ignore */ - } - else - { - fvalue = new_fvalue; - fdigits++; - } - continue; - default: - break; - } - break; - } + for (buf++; buf < end; buf++) + { + int v = *buf; + int new_fvalue; + switch (v) + { + case 0x30: + case 0x31: + case 0x32: + case 0x33: + case 0x34: + case 0x35: + case 0x36: + case 0x37: + case 0x38: + case 0x39: + new_fvalue = fvalue * 10 + (v - 0x30); + if (new_fvalue / 10 != fvalue) + { + /* Not enough precision, ignore */ + } + else + { + fvalue = new_fvalue; + fdigits++; + } + continue; + default: + break; + } + break; + } } if (buf == end) goto local_finish; switch (*buf) { - case 0x2B: - case 0x2D: /* +, - */ - goto offset; - case 0x5A: /* Z */ - goto utc_finish; - default: - errno = EINVAL; - return -1; + case 0x2B: + case 0x2D: /* +, - */ + goto offset; + case 0x5A: /* Z */ + goto utc_finish; + default: + errno = EINVAL; + return -1; } offset: @@ -681,14 +681,14 @@ local_finish: } GeneralizedTime_t *asn_time2GT(GeneralizedTime_t *opt_gt, const struct tm *tm, - int force_gmt) + int force_gmt) { return asn_time2GT_frac(opt_gt, tm, 0, 0, force_gmt); } GeneralizedTime_t *asn_time2GT_frac(GeneralizedTime_t *opt_gt, - const struct tm *tm, int frac_value, - int frac_digits, int force_gmt) + const struct tm *tm, int frac_value, + int frac_digits, int force_gmt) { struct tm tm_s; long gmtoff; @@ -729,8 +729,8 @@ GeneralizedTime_t *asn_time2GT_frac(GeneralizedTime_t *opt_gt, } size = snprintf(buf, buf_size, "%04d%02d%02d%02d%02d%02d", - tm->tm_year + 1900, tm->tm_mon + 1, tm->tm_mday, - tm->tm_hour, tm->tm_min, tm->tm_sec); + tm->tm_year + 1900, tm->tm_mon + 1, tm->tm_mday, + tm->tm_hour, tm->tm_min, tm->tm_sec); if (size != 14) { /* Could be assert(size == 14); */ @@ -790,7 +790,7 @@ GeneralizedTime_t *asn_time2GT_frac(GeneralizedTime_t *opt_gt, int ret; gmtoff %= 86400; ret = snprintf(p, buf_size - size, "%+03ld%02ld", gmtoff / 3600, - labs(gmtoff % 3600) / 60); + labs(gmtoff % 3600) / 60); if (ret != 5) { FREEMEM(buf); diff --git a/src/core/libs/supl/asn-supl/GeneralizedTime.h b/src/core/libs/supl/asn-supl/GeneralizedTime.h index 2d73d7852..605bea4d2 100644 --- a/src/core/libs/supl/asn-supl/GeneralizedTime.h +++ b/src/core/libs/supl/asn-supl/GeneralizedTime.h @@ -35,13 +35,13 @@ extern "C" * On error returns -1 and errno set to EINVAL */ time_t asn_GT2time(const GeneralizedTime_t * /*st*/, struct tm *ret_tm, - int as_gmt); + int as_gmt); /* A version of the above function also returning the fractions of seconds */ time_t asn_GT2time_frac(const GeneralizedTime_t * /*st*/, int *frac_value, - int *frac_digits, /* (value / (10 ^ digits)) */ - struct tm *ret_tm, int as_gmt); + int *frac_digits, /* (value / (10 ^ digits)) */ + struct tm *ret_tm, int as_gmt); /* * Another version returning fractions with defined precision @@ -49,7 +49,7 @@ extern "C" * with frac_digits=3 (msec) would yield frac_value = 100. */ time_t asn_GT2time_prec(const GeneralizedTime_t * /*st*/, int *frac_value, - int frac_digits, struct tm *ret_tm, int as_gmt); + int frac_digits, struct tm *ret_tm, int as_gmt); /* * Convert a struct tm into GeneralizedTime. @@ -59,11 +59,11 @@ extern "C" * On error, this function returns 0 and sets errno. */ GeneralizedTime_t *asn_time2GT(GeneralizedTime_t *opt_gt, - const struct tm * /*tm*/, int force_gmt); + const struct tm * /*tm*/, int force_gmt); GeneralizedTime_t *asn_time2GT_frac(GeneralizedTime_t *opt_gt, - const struct tm * /*tm*/, - int frac_value, int frac_digits, - int force_gmt); + const struct tm * /*tm*/, + int frac_value, int frac_digits, + int force_gmt); #ifdef __cplusplus } diff --git a/src/core/libs/supl/asn-supl/GsmCellInformation.c b/src/core/libs/supl/asn-supl/GsmCellInformation.c index c9c57cca3..f9f0b2b69 100644 --- a/src/core/libs/supl/asn-supl/GsmCellInformation.c +++ b/src/core/libs/supl/asn-supl/GsmCellInformation.c @@ -7,15 +7,15 @@ #include "GsmCellInformation.h" static int memb_refMCC_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,21 +29,21 @@ static int memb_refMCC_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_refMNC_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -57,21 +57,21 @@ static int memb_refMNC_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_refLAC_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -85,21 +85,21 @@ static int memb_refLAC_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_refCI_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -113,21 +113,21 @@ static int memb_refCI_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_tA_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -141,7 +141,7 @@ static int memb_tA_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -178,30 +178,30 @@ static asn_per_constraints_t ASN_PER_MEMB_T_A_CONSTR_7 = { }; static asn_TYPE_member_t asn_MBR_GsmCellInformation_1[] = { {ATF_NOFLAGS, 0, offsetof(struct GsmCellInformation, refMCC), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_refMCC_constraint_1, - &ASN_PER_MEMB_REF_MCC_CONSTR_2, 0, "refMCC"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_refMCC_constraint_1, + &ASN_PER_MEMB_REF_MCC_CONSTR_2, 0, "refMCC"}, {ATF_NOFLAGS, 0, offsetof(struct GsmCellInformation, refMNC), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_refMNC_constraint_1, - &ASN_PER_MEMB_REF_MNC_CONSTR_3, 0, "refMNC"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_refMNC_constraint_1, + &ASN_PER_MEMB_REF_MNC_CONSTR_3, 0, "refMNC"}, {ATF_NOFLAGS, 0, offsetof(struct GsmCellInformation, refLAC), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_refLAC_constraint_1, - &ASN_PER_MEMB_REF_LAC_CONSTR_4, 0, "refLAC"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_refLAC_constraint_1, + &ASN_PER_MEMB_REF_LAC_CONSTR_4, 0, "refLAC"}, {ATF_NOFLAGS, 0, offsetof(struct GsmCellInformation, refCI), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_refCI_constraint_1, - &ASN_PER_MEMB_REF_CI_CONSTR_5, 0, "refCI"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_refCI_constraint_1, + &ASN_PER_MEMB_REF_CI_CONSTR_5, 0, "refCI"}, {ATF_POINTER, 2, offsetof(struct GsmCellInformation, nMR), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NMR, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "nMR"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NMR, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "nMR"}, {ATF_POINTER, 1, offsetof(struct GsmCellInformation, tA), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_tA_constraint_1, &ASN_PER_MEMB_T_A_CONSTR_7, - 0, "tA"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_tA_constraint_1, &ASN_PER_MEMB_T_A_CONSTR_7, + 0, "tA"}, }; static int asn_MAP_GsmCellInformation_oms_1[] = {4, 5}; static ber_tlv_tag_t asn_DEF_GsmCellInformation_tags_1[] = { @@ -244,7 +244,7 @@ asn_TYPE_descriptor_t asn_DEF_GsmCellInformation = { asn_DEF_GsmCellInformation_tags_1, /* Same as above */ sizeof(asn_DEF_GsmCellInformation_tags_1) / sizeof(asn_DEF_GsmCellInformation_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_GsmCellInformation_1, 6, /* Elements count */ &asn_SPC_GsmCellInformation_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-supl/Horandveruncert.c b/src/core/libs/supl/asn-supl/Horandveruncert.c index f9cc33e4a..44afc7bee 100644 --- a/src/core/libs/supl/asn-supl/Horandveruncert.c +++ b/src/core/libs/supl/asn-supl/Horandveruncert.c @@ -7,9 +7,9 @@ #include "Horandveruncert.h" static int memb_verdirect_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const BIT_STRING_t *st = (const BIT_STRING_t *)sptr; size_t size; @@ -17,7 +17,7 @@ static int memb_verdirect_constraint_1(asn_TYPE_descriptor_t *td, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -39,15 +39,15 @@ static int memb_verdirect_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_bearing_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const BIT_STRING_t *st = (const BIT_STRING_t *)sptr; size_t size; @@ -55,7 +55,7 @@ static int memb_bearing_constraint_1(asn_TYPE_descriptor_t *td, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -77,15 +77,15 @@ static int memb_bearing_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_horspeed_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const BIT_STRING_t *st = (const BIT_STRING_t *)sptr; size_t size; @@ -93,7 +93,7 @@ static int memb_horspeed_constraint_1(asn_TYPE_descriptor_t *td, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -115,15 +115,15 @@ static int memb_horspeed_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_verspeed_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const BIT_STRING_t *st = (const BIT_STRING_t *)sptr; size_t size; @@ -131,7 +131,7 @@ static int memb_verspeed_constraint_1(asn_TYPE_descriptor_t *td, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -153,7 +153,7 @@ static int memb_verspeed_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -168,7 +168,7 @@ static int memb_horuncertspeed_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -190,7 +190,7 @@ static int memb_horuncertspeed_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -205,7 +205,7 @@ static int memb_veruncertspeed_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -227,7 +227,7 @@ static int memb_veruncertspeed_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -270,29 +270,29 @@ static asn_per_constraints_t ASN_PER_MEMB_VERUNCERTSPEED_CONSTR_7 = { }; static asn_TYPE_member_t asn_MBR_Horandveruncert_1[] = { {ATF_NOFLAGS, 0, offsetof(struct Horandveruncert, verdirect), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BIT_STRING, memb_verdirect_constraint_1, - &ASN_PER_MEMB_VERDIRECT_CONSTR_2, 0, "verdirect"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BIT_STRING, memb_verdirect_constraint_1, + &ASN_PER_MEMB_VERDIRECT_CONSTR_2, 0, "verdirect"}, {ATF_NOFLAGS, 0, offsetof(struct Horandveruncert, bearing), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BIT_STRING, memb_bearing_constraint_1, - &ASN_PER_MEMB_BEARING_CONSTR_3, 0, "bearing"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BIT_STRING, memb_bearing_constraint_1, + &ASN_PER_MEMB_BEARING_CONSTR_3, 0, "bearing"}, {ATF_NOFLAGS, 0, offsetof(struct Horandveruncert, horspeed), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BIT_STRING, memb_horspeed_constraint_1, - &ASN_PER_MEMB_HORSPEED_CONSTR_4, 0, "horspeed"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BIT_STRING, memb_horspeed_constraint_1, + &ASN_PER_MEMB_HORSPEED_CONSTR_4, 0, "horspeed"}, {ATF_NOFLAGS, 0, offsetof(struct Horandveruncert, verspeed), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BIT_STRING, memb_verspeed_constraint_1, - &ASN_PER_MEMB_VERSPEED_CONSTR_5, 0, "verspeed"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BIT_STRING, memb_verspeed_constraint_1, + &ASN_PER_MEMB_VERSPEED_CONSTR_5, 0, "verspeed"}, {ATF_NOFLAGS, 0, offsetof(struct Horandveruncert, horuncertspeed), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BIT_STRING, memb_horuncertspeed_constraint_1, - &ASN_PER_MEMB_HORUNCERTSPEED_CONSTR_6, 0, "horuncertspeed"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BIT_STRING, memb_horuncertspeed_constraint_1, + &ASN_PER_MEMB_HORUNCERTSPEED_CONSTR_6, 0, "horuncertspeed"}, {ATF_NOFLAGS, 0, offsetof(struct Horandveruncert, veruncertspeed), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BIT_STRING, memb_veruncertspeed_constraint_1, - &ASN_PER_MEMB_VERUNCERTSPEED_CONSTR_7, 0, "veruncertspeed"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BIT_STRING, memb_veruncertspeed_constraint_1, + &ASN_PER_MEMB_VERUNCERTSPEED_CONSTR_7, 0, "veruncertspeed"}, }; static ber_tlv_tag_t asn_DEF_Horandveruncert_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -334,7 +334,7 @@ asn_TYPE_descriptor_t asn_DEF_Horandveruncert = { asn_DEF_Horandveruncert_tags_1, /* Same as above */ sizeof(asn_DEF_Horandveruncert_tags_1) / sizeof(asn_DEF_Horandveruncert_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_Horandveruncert_1, 6, /* Elements count */ &asn_SPC_Horandveruncert_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-supl/Horandvervel.c b/src/core/libs/supl/asn-supl/Horandvervel.c index 919972d8b..9f2e02845 100644 --- a/src/core/libs/supl/asn-supl/Horandvervel.c +++ b/src/core/libs/supl/asn-supl/Horandvervel.c @@ -7,9 +7,9 @@ #include "Horandvervel.h" static int memb_verdirect_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const BIT_STRING_t *st = (const BIT_STRING_t *)sptr; size_t size; @@ -17,7 +17,7 @@ static int memb_verdirect_constraint_1(asn_TYPE_descriptor_t *td, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -39,15 +39,15 @@ static int memb_verdirect_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_bearing_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const BIT_STRING_t *st = (const BIT_STRING_t *)sptr; size_t size; @@ -55,7 +55,7 @@ static int memb_bearing_constraint_1(asn_TYPE_descriptor_t *td, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -77,15 +77,15 @@ static int memb_bearing_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_horspeed_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const BIT_STRING_t *st = (const BIT_STRING_t *)sptr; size_t size; @@ -93,7 +93,7 @@ static int memb_horspeed_constraint_1(asn_TYPE_descriptor_t *td, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -115,15 +115,15 @@ static int memb_horspeed_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_verspeed_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const BIT_STRING_t *st = (const BIT_STRING_t *)sptr; size_t size; @@ -131,7 +131,7 @@ static int memb_verspeed_constraint_1(asn_TYPE_descriptor_t *td, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -153,7 +153,7 @@ static int memb_verspeed_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -184,21 +184,21 @@ static asn_per_constraints_t ASN_PER_MEMB_VERSPEED_CONSTR_5 = { }; static asn_TYPE_member_t asn_MBR_Horandvervel_1[] = { {ATF_NOFLAGS, 0, offsetof(struct Horandvervel, verdirect), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BIT_STRING, memb_verdirect_constraint_1, - &ASN_PER_MEMB_VERDIRECT_CONSTR_2, 0, "verdirect"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BIT_STRING, memb_verdirect_constraint_1, + &ASN_PER_MEMB_VERDIRECT_CONSTR_2, 0, "verdirect"}, {ATF_NOFLAGS, 0, offsetof(struct Horandvervel, bearing), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BIT_STRING, memb_bearing_constraint_1, - &ASN_PER_MEMB_BEARING_CONSTR_3, 0, "bearing"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BIT_STRING, memb_bearing_constraint_1, + &ASN_PER_MEMB_BEARING_CONSTR_3, 0, "bearing"}, {ATF_NOFLAGS, 0, offsetof(struct Horandvervel, horspeed), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BIT_STRING, memb_horspeed_constraint_1, - &ASN_PER_MEMB_HORSPEED_CONSTR_4, 0, "horspeed"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BIT_STRING, memb_horspeed_constraint_1, + &ASN_PER_MEMB_HORSPEED_CONSTR_4, 0, "horspeed"}, {ATF_NOFLAGS, 0, offsetof(struct Horandvervel, verspeed), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BIT_STRING, memb_verspeed_constraint_1, - &ASN_PER_MEMB_VERSPEED_CONSTR_5, 0, "verspeed"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BIT_STRING, memb_verspeed_constraint_1, + &ASN_PER_MEMB_VERSPEED_CONSTR_5, 0, "verspeed"}, }; static ber_tlv_tag_t asn_DEF_Horandvervel_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-supl/Horvel.c b/src/core/libs/supl/asn-supl/Horvel.c index fbb52a8e5..cf97e2462 100644 --- a/src/core/libs/supl/asn-supl/Horvel.c +++ b/src/core/libs/supl/asn-supl/Horvel.c @@ -7,9 +7,9 @@ #include "Horvel.h" static int memb_bearing_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const BIT_STRING_t *st = (const BIT_STRING_t *)sptr; size_t size; @@ -17,7 +17,7 @@ static int memb_bearing_constraint_1(asn_TYPE_descriptor_t *td, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -39,15 +39,15 @@ static int memb_bearing_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_horspeed_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const BIT_STRING_t *st = (const BIT_STRING_t *)sptr; size_t size; @@ -55,7 +55,7 @@ static int memb_horspeed_constraint_1(asn_TYPE_descriptor_t *td, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -77,7 +77,7 @@ static int memb_horspeed_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -96,13 +96,13 @@ static asn_per_constraints_t ASN_PER_MEMB_HORSPEED_CONSTR_3 = { }; static asn_TYPE_member_t asn_MBR_Horvel_1[] = { {ATF_NOFLAGS, 0, offsetof(struct Horvel, bearing), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BIT_STRING, memb_bearing_constraint_1, - &ASN_PER_MEMB_BEARING_CONSTR_2, 0, "bearing"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BIT_STRING, memb_bearing_constraint_1, + &ASN_PER_MEMB_BEARING_CONSTR_2, 0, "bearing"}, {ATF_NOFLAGS, 0, offsetof(struct Horvel, horspeed), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BIT_STRING, memb_horspeed_constraint_1, - &ASN_PER_MEMB_HORSPEED_CONSTR_3, 0, "horspeed"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BIT_STRING, memb_horspeed_constraint_1, + &ASN_PER_MEMB_HORSPEED_CONSTR_3, 0, "horspeed"}, }; static ber_tlv_tag_t asn_DEF_Horvel_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -136,9 +136,9 @@ asn_TYPE_descriptor_t asn_DEF_Horvel = { 0, /* Use generic outmost tag fetcher */ asn_DEF_Horvel_tags_1, sizeof(asn_DEF_Horvel_tags_1) / sizeof(asn_DEF_Horvel_tags_1[0]), /* 1 */ - asn_DEF_Horvel_tags_1, /* Same as above */ + asn_DEF_Horvel_tags_1, /* Same as above */ sizeof(asn_DEF_Horvel_tags_1) / sizeof(asn_DEF_Horvel_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_Horvel_1, 2, /* Elements count */ &asn_SPC_Horvel_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-supl/Horveluncert.c b/src/core/libs/supl/asn-supl/Horveluncert.c index 344465dd7..362757590 100644 --- a/src/core/libs/supl/asn-supl/Horveluncert.c +++ b/src/core/libs/supl/asn-supl/Horveluncert.c @@ -7,9 +7,9 @@ #include "Horveluncert.h" static int memb_bearing_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const BIT_STRING_t *st = (const BIT_STRING_t *)sptr; size_t size; @@ -17,7 +17,7 @@ static int memb_bearing_constraint_1(asn_TYPE_descriptor_t *td, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -39,15 +39,15 @@ static int memb_bearing_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_horspeed_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const BIT_STRING_t *st = (const BIT_STRING_t *)sptr; size_t size; @@ -55,7 +55,7 @@ static int memb_horspeed_constraint_1(asn_TYPE_descriptor_t *td, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -77,15 +77,15 @@ static int memb_horspeed_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_uncertspeed_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const BIT_STRING_t *st = (const BIT_STRING_t *)sptr; size_t size; @@ -93,7 +93,7 @@ static int memb_uncertspeed_constraint_1(asn_TYPE_descriptor_t *td, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -115,7 +115,7 @@ static int memb_uncertspeed_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -140,17 +140,17 @@ static asn_per_constraints_t ASN_PER_MEMB_UNCERTSPEED_CONSTR_4 = { }; static asn_TYPE_member_t asn_MBR_Horveluncert_1[] = { {ATF_NOFLAGS, 0, offsetof(struct Horveluncert, bearing), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BIT_STRING, memb_bearing_constraint_1, - &ASN_PER_MEMB_BEARING_CONSTR_2, 0, "bearing"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BIT_STRING, memb_bearing_constraint_1, + &ASN_PER_MEMB_BEARING_CONSTR_2, 0, "bearing"}, {ATF_NOFLAGS, 0, offsetof(struct Horveluncert, horspeed), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BIT_STRING, memb_horspeed_constraint_1, - &ASN_PER_MEMB_HORSPEED_CONSTR_3, 0, "horspeed"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BIT_STRING, memb_horspeed_constraint_1, + &ASN_PER_MEMB_HORSPEED_CONSTR_3, 0, "horspeed"}, {ATF_NOFLAGS, 0, offsetof(struct Horveluncert, uncertspeed), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BIT_STRING, memb_uncertspeed_constraint_1, - &ASN_PER_MEMB_UNCERTSPEED_CONSTR_4, 0, "uncertspeed"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BIT_STRING, memb_uncertspeed_constraint_1, + &ASN_PER_MEMB_UNCERTSPEED_CONSTR_4, 0, "uncertspeed"}, }; static ber_tlv_tag_t asn_DEF_Horveluncert_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-supl/IA5String.c b/src/core/libs/supl/asn-supl/IA5String.c index 187acb0b8..72055bcd0 100644 --- a/src/core/libs/supl/asn-supl/IA5String.c +++ b/src/core/libs/supl/asn-supl/IA5String.c @@ -2,8 +2,8 @@ * Copyright (c) 2003 Lev Walkin . All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ -#include #include +#include /* * IA5String basic type description. @@ -41,7 +41,7 @@ asn_TYPE_descriptor_t asn_DEF_IA5String = { }; int IA5String_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { const IA5String_t *st = (const IA5String_t *)sptr; @@ -58,10 +58,10 @@ int IA5String_constraint(asn_TYPE_descriptor_t *td, const void *sptr, if (*buf > 0x7F) { _ASN_CTFAIL(app_key, td, sptr, - "%s: value byte %ld out of range: " - "%d > 127 (%s:%d)", - td->name, ((buf - st->buf) + 1), *buf, - __FILE__, __LINE__); + "%s: value byte %ld out of range: " + "%d > 127 (%s:%d)", + td->name, ((buf - st->buf) + 1), *buf, + __FILE__, __LINE__); return -1; } } @@ -69,7 +69,7 @@ int IA5String_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } diff --git a/src/core/libs/supl/asn-supl/INTEGER.c b/src/core/libs/supl/asn-supl/INTEGER.c index 3a0f90a47..65878c16c 100644 --- a/src/core/libs/supl/asn-supl/INTEGER.c +++ b/src/core/libs/supl/asn-supl/INTEGER.c @@ -3,9 +3,9 @@ * All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ -#include #include #include /* Encoder and decoder of a primitive type */ +#include #include #include @@ -41,13 +41,13 @@ asn_TYPE_descriptor_t asn_DEF_INTEGER = { * Encode INTEGER type using DER. */ asn_enc_rval_t INTEGER_encode_der(asn_TYPE_descriptor_t *td, void *sptr, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { INTEGER_t *st = (INTEGER_t *)sptr; ASN_DEBUG("%s %s as INTEGER (tm=%d)", cb ? "Encoding" : "Estimating", - td->name, tag_mode); + td->name, tag_mode); /* * Canonicalize integer in the buffer. @@ -71,12 +71,12 @@ asn_enc_rval_t INTEGER_encode_der(asn_TYPE_descriptor_t *td, void *sptr, */ switch (*buf) { - case 0x00: - if ((buf[1] & 0x80) == 0) continue; - break; - case 0xff: - if ((buf[1] & 0x80)) continue; - break; + case 0x00: + if ((buf[1] & 0x80) == 0) continue; + break; + case 0xff: + if ((buf[1] & 0x80)) continue; + break; } break; } @@ -106,8 +106,8 @@ static const asn_INTEGER_enum_map_t *INTEGER_map_enum2value( * INTEGER specific human-readable output. */ static ssize_t INTEGER__dump(asn_TYPE_descriptor_t *td, const INTEGER_t *st, - asn_app_consume_bytes_f *cb, void *app_key, - int plainOrXER) + asn_app_consume_bytes_f *cb, void *app_key, + int plainOrXER) { asn_INTEGER_specifics_t *specs = (asn_INTEGER_specifics_t *)td->specifics; char scratch[32]; /* Enough for 64-bit integer */ @@ -129,12 +129,12 @@ static ssize_t INTEGER__dump(asn_TYPE_descriptor_t *td, const INTEGER_t *st, { switch (*buf) { - case 0x00: - if ((buf[1] & 0x80) == 0) continue; - break; - case 0xff: - if ((buf[1] & 0x80) != 0) continue; - break; + case 0x00: + if ((buf[1] & 0x80) == 0) continue; + break; + case 0xff: + if ((buf[1] & 0x80) != 0) continue; + break; } break; } @@ -163,7 +163,7 @@ static ssize_t INTEGER__dump(asn_TYPE_descriptor_t *td, const INTEGER_t *st, scr = (char *)alloca(scrsize); if (plainOrXER == 0) ret = snprintf(scr, scrsize, "%+" PRId64 "(%s)", accum, - el->enum_name); + el->enum_name); else ret = snprintf(scr, scrsize, "<%s/>", el->enum_name); } @@ -181,9 +181,9 @@ static ssize_t INTEGER__dump(asn_TYPE_descriptor_t *td, const INTEGER_t *st, scr = scratch; ret = snprintf(scr, scrsize, - (specs && specs->field_unsigned) ? "%" PRIu64 - : "%+" PRId64, - accum); + (specs && specs->field_unsigned) ? "%" PRIu64 + : "%+" PRId64, + accum); } assert(ret > 0 && (size_t)ret < scrsize); return (cb(scr, ret, app_key) < 0) ? -1 : ret; @@ -227,7 +227,7 @@ static ssize_t INTEGER__dump(asn_TYPE_descriptor_t *td, const INTEGER_t *st, * INTEGER specific human-readable output. */ int INTEGER_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { const INTEGER_t *st = (const INTEGER_t *)sptr; ssize_t ret; @@ -288,17 +288,17 @@ static const asn_INTEGER_enum_map_t *INTEGER_map_enum2value( { switch (*lp) { - case 9: - case 10: - case 11: - case 12: - case 13: - case 32: /* WSP */ - case 0x2f: /* '/' */ - case 0x3e: /* '>' */ - break; - default: - continue; + case 9: + case 10: + case 11: + case 12: + case 13: + case 32: /* WSP */ + case 0x2f: /* '/' */ + case 0x3e: /* '>' */ + break; + default: + continue; } break; } @@ -310,8 +310,8 @@ static const asn_INTEGER_enum_map_t *INTEGER_map_enum2value( key.vemap = specs->value2enum; key.evmap = specs->enum2value; el_found = (asn_INTEGER_enum_map_t *)bsearch(&key, specs->value2enum, count, - sizeof(specs->value2enum[0]), - INTEGER__compar_enum2value); + sizeof(specs->value2enum[0]), + INTEGER__compar_enum2value); if (el_found) { /* Remap enum2value into value2enum */ @@ -339,8 +339,8 @@ const asn_INTEGER_enum_map_t *INTEGER_map_value2enum( int count = specs ? specs->map_count : 0; if (!count) return 0; return (asn_INTEGER_enum_map_t *)bsearch(&value, specs->value2enum, count, - sizeof(specs->value2enum[0]), - INTEGER__compar_value2enum); + sizeof(specs->value2enum[0]), + INTEGER__compar_value2enum); } static int INTEGER_st_prealloc(INTEGER_t *st, int min_size) @@ -364,9 +364,9 @@ static int INTEGER_st_prealloc(INTEGER_t *st, int min_size) * Decode the chunk of XML text encoding INTEGER. */ static enum xer_pbd_rval INTEGER__xer_body_decode(asn_TYPE_descriptor_t *td, - void *sptr, - const void *chunk_buf, - size_t chunk_size) + void *sptr, + const void *chunk_buf, + size_t chunk_size) { INTEGER_t *st = (INTEGER_t *)sptr; int64_t sign = 1LL; @@ -388,7 +388,7 @@ static enum xer_pbd_rval INTEGER__xer_body_decode(asn_TYPE_descriptor_t *td, if (chunk_size) ASN_DEBUG("INTEGER body %ld 0x%2x..0x%2x", (int64_t)chunk_size, *lstart, - lstop[-1]); + lstop[-1]); /* * We may have received a tag here. It will be processed inline. @@ -399,183 +399,183 @@ static enum xer_pbd_rval INTEGER__xer_body_decode(asn_TYPE_descriptor_t *td, int lv = *lp; switch (lv) { - case 0x09: - case 0x0a: - case 0x0d: - case 0x20: - switch (state) - { - case ST_SKIPSPACE: - case ST_SKIPSPHEX: - continue; - case ST_HEXCOLON: - if (xer_is_whitespace(lp, lstop - lp)) - { - lp = lstop - 1; - continue; - } - break; - default: - break; - } - break; - case 0x2d: /* '-' */ - if (state == ST_SKIPSPACE) - { - sign = -1; - state = ST_WAITDIGITS; - continue; - } - break; - case 0x2b: /* '+' */ - if (state == ST_SKIPSPACE) - { - state = ST_WAITDIGITS; - continue; - } - break; - case 0x30: - case 0x31: - case 0x32: - case 0x33: - case 0x34: - case 0x35: - case 0x36: - case 0x37: - case 0x38: - case 0x39: - switch (state) - { - case ST_DIGITS: - break; - case ST_SKIPSPHEX: /* Fall through */ - case ST_HEXDIGIT1: - value = (lv - 0x30) << 4; - state = ST_HEXDIGIT2; - continue; - case ST_HEXDIGIT2: - value += (lv - 0x30); - state = ST_HEXCOLON; - st->buf[st->size++] = (uint8_t)value; - continue; - case ST_HEXCOLON: - return XPBD_BROKEN_ENCODING; - default: - state = ST_DIGITS; - break; - } - + case 0x09: + case 0x0a: + case 0x0d: + case 0x20: + switch (state) { - int64_t new_value = value * 10; - - if (new_value / 10 != value) /* Overflow */ - return XPBD_DECODER_LIMIT; - - value = new_value + (lv - 0x30); - /* Check for two's complement overflow */ - if (value < 0) + case ST_SKIPSPACE: + case ST_SKIPSPHEX: + continue; + case ST_HEXCOLON: + if (xer_is_whitespace(lp, lstop - lp)) { - /* Check whether it is a LONG_MIN */ - if (sign == -1 && - (uint64_t)value == ~((uint64_t)-1 >> 1)) - { - sign = 1; - } - else - { - /* Overflow */ - return XPBD_DECODER_LIMIT; - } + lp = lstop - 1; + continue; } + break; + default: + break; } - continue; - case 0x3c: /* '<' */ - if (state == ST_SKIPSPACE) + break; + case 0x2d: /* '-' */ + if (state == ST_SKIPSPACE) + { + sign = -1; + state = ST_WAITDIGITS; + continue; + } + break; + case 0x2b: /* '+' */ + if (state == ST_SKIPSPACE) + { + state = ST_WAITDIGITS; + continue; + } + break; + case 0x30: + case 0x31: + case 0x32: + case 0x33: + case 0x34: + case 0x35: + case 0x36: + case 0x37: + case 0x38: + case 0x39: + switch (state) + { + case ST_DIGITS: + break; + case ST_SKIPSPHEX: /* Fall through */ + case ST_HEXDIGIT1: + value = (lv - 0x30) << 4; + state = ST_HEXDIGIT2; + continue; + case ST_HEXDIGIT2: + value += (lv - 0x30); + state = ST_HEXCOLON; + st->buf[st->size++] = (uint8_t)value; + continue; + case ST_HEXCOLON: + return XPBD_BROKEN_ENCODING; + default: + state = ST_DIGITS; + break; + } + + { + int64_t new_value = value * 10; + + if (new_value / 10 != value) /* Overflow */ + return XPBD_DECODER_LIMIT; + + value = new_value + (lv - 0x30); + /* Check for two's complement overflow */ + if (value < 0) { - const asn_INTEGER_enum_map_t *el; - el = INTEGER_map_enum2value( - (asn_INTEGER_specifics_t *)td->specifics, - lstart, lstop); - if (el) + /* Check whether it is a LONG_MIN */ + if (sign == -1 && + (uint64_t)value == ~((uint64_t)-1 >> 1)) { - ASN_DEBUG("Found \"%s\" => %ld", - el->enum_name, el->nat_value); - state = ST_DIGITS; - value = el->nat_value; - lp = lstop - 1; - continue; + sign = 1; + } + else + { + /* Overflow */ + return XPBD_DECODER_LIMIT; } - ASN_DEBUG("Unknown identifier for INTEGER"); } - return XPBD_BROKEN_ENCODING; - case 0x3a: /* ':' */ - if (state == ST_HEXCOLON) - { - /* This colon is expected */ - state = ST_HEXDIGIT1; - continue; - } - else if (state == ST_DIGITS) - { - /* The colon here means that we have + } + continue; + case 0x3c: /* '<' */ + if (state == ST_SKIPSPACE) + { + const asn_INTEGER_enum_map_t *el; + el = INTEGER_map_enum2value( + (asn_INTEGER_specifics_t *)td->specifics, + lstart, lstop); + if (el) + { + ASN_DEBUG("Found \"%s\" => %ld", + el->enum_name, el->nat_value); + state = ST_DIGITS; + value = el->nat_value; + lp = lstop - 1; + continue; + } + ASN_DEBUG("Unknown identifier for INTEGER"); + } + return XPBD_BROKEN_ENCODING; + case 0x3a: /* ':' */ + if (state == ST_HEXCOLON) + { + /* This colon is expected */ + state = ST_HEXDIGIT1; + continue; + } + else if (state == ST_DIGITS) + { + /* The colon here means that we have * decoded the first two hexadecimal * places as a decimal value. * Switch decoding mode. */ - ASN_DEBUG("INTEGER re-evaluate as hex form"); - if (INTEGER_st_prealloc(st, - (chunk_size / 3) + 1)) - return XPBD_SYSTEM_FAILURE; - state = ST_SKIPSPHEX; - lp = lstart - 1; - continue; - } - else - { - ASN_DEBUG("state %d at %d", state, lp - lstart); - break; - } - /* [A-Fa-f] */ - case 0x41: - case 0x42: - case 0x43: - case 0x44: - case 0x45: - case 0x46: - case 0x61: - case 0x62: - case 0x63: - case 0x64: - case 0x65: - case 0x66: - switch (state) - { - case ST_SKIPSPHEX: - case ST_SKIPSPACE: /* Fall through */ - case ST_HEXDIGIT1: - value = lv - ((lv < 0x61) ? 0x41 : 0x61); - value += 10; - value <<= 4; - state = ST_HEXDIGIT2; - continue; - case ST_HEXDIGIT2: - value += lv - ((lv < 0x61) ? 0x41 : 0x61); - value += 10; - st->buf[st->size++] = (uint8_t)value; - state = ST_HEXCOLON; - continue; - case ST_DIGITS: - ASN_DEBUG( - "INTEGER re-evaluate as hex form"); - if (INTEGER_st_prealloc( - st, (chunk_size / 3) + 1)) - return XPBD_SYSTEM_FAILURE; - state = ST_SKIPSPHEX; - lp = lstart - 1; - continue; - default: - break; - } - break; + ASN_DEBUG("INTEGER re-evaluate as hex form"); + if (INTEGER_st_prealloc(st, + (chunk_size / 3) + 1)) + return XPBD_SYSTEM_FAILURE; + state = ST_SKIPSPHEX; + lp = lstart - 1; + continue; + } + else + { + ASN_DEBUG("state %d at %d", state, lp - lstart); + break; + } + /* [A-Fa-f] */ + case 0x41: + case 0x42: + case 0x43: + case 0x44: + case 0x45: + case 0x46: + case 0x61: + case 0x62: + case 0x63: + case 0x64: + case 0x65: + case 0x66: + switch (state) + { + case ST_SKIPSPHEX: + case ST_SKIPSPACE: /* Fall through */ + case ST_HEXDIGIT1: + value = lv - ((lv < 0x61) ? 0x41 : 0x61); + value += 10; + value <<= 4; + state = ST_HEXDIGIT2; + continue; + case ST_HEXDIGIT2: + value += lv - ((lv < 0x61) ? 0x41 : 0x61); + value += 10; + st->buf[st->size++] = (uint8_t)value; + state = ST_HEXCOLON; + continue; + case ST_DIGITS: + ASN_DEBUG( + "INTEGER re-evaluate as hex form"); + if (INTEGER_st_prealloc( + st, (chunk_size / 3) + 1)) + return XPBD_SYSTEM_FAILURE; + state = ST_SKIPSPHEX; + lp = lstart - 1; + continue; + default: + break; + } + break; } /* Found extra non-numeric stuff */ @@ -586,29 +586,29 @@ static enum xer_pbd_rval INTEGER__xer_body_decode(asn_TYPE_descriptor_t *td, switch (state) { - case ST_DIGITS: - /* Everything is cool */ - break; - case ST_HEXCOLON: - st->buf[st->size] = 0; /* Just in case termination */ - return XPBD_BODY_CONSUMED; - case ST_HEXDIGIT1: - case ST_HEXDIGIT2: - case ST_SKIPSPHEX: - return XPBD_BROKEN_ENCODING; - default: - if (xer_is_whitespace(lp, lstop - lp)) - { - if (state != ST_EXTRASTUFF) return XPBD_NOT_BODY_IGNORE; - break; - } - else - { - ASN_DEBUG("INTEGER: No useful digits (state %d)", - state); - return XPBD_BROKEN_ENCODING; /* No digits */ - } - break; + case ST_DIGITS: + /* Everything is cool */ + break; + case ST_HEXCOLON: + st->buf[st->size] = 0; /* Just in case termination */ + return XPBD_BODY_CONSUMED; + case ST_HEXDIGIT1: + case ST_HEXDIGIT2: + case ST_SKIPSPHEX: + return XPBD_BROKEN_ENCODING; + default: + if (xer_is_whitespace(lp, lstop - lp)) + { + if (state != ST_EXTRASTUFF) return XPBD_NOT_BODY_IGNORE; + break; + } + else + { + ASN_DEBUG("INTEGER: No useful digits (state %d)", + state); + return XPBD_BROKEN_ENCODING; /* No digits */ + } + break; } value *= sign; /* Change sign, if needed */ @@ -619,18 +619,18 @@ static enum xer_pbd_rval INTEGER__xer_body_decode(asn_TYPE_descriptor_t *td, } asn_dec_rval_t INTEGER_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **sptr, - const char *opt_mname, const void *buf_ptr, - size_t size) + asn_TYPE_descriptor_t *td, void **sptr, + const char *opt_mname, const void *buf_ptr, + size_t size) { return xer_decode_primitive(opt_codec_ctx, td, sptr, sizeof(INTEGER_t), - opt_mname, buf_ptr, size, - INTEGER__xer_body_decode); + opt_mname, buf_ptr, size, + INTEGER__xer_body_decode); } asn_enc_rval_t INTEGER_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { const INTEGER_t *st = (const INTEGER_t *)sptr; asn_enc_rval_t er; @@ -647,9 +647,9 @@ asn_enc_rval_t INTEGER_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, } asn_dec_rval_t INTEGER_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd) { asn_INTEGER_specifics_t *specs = (asn_INTEGER_specifics_t *)td->specifics; asn_dec_rval_t rval = {RC_OK, 0}; @@ -718,7 +718,7 @@ asn_dec_rval_t INTEGER_decode_uper(asn_codec_ctx_t *opt_codec_ctx, if (value < 0) _ASN_DECODE_STARVED; } ASN_DEBUG("Got value %ld + low %ld", value, - ct->lower_bound); + ct->lower_bound); value += ct->lower_bound; if ((specs && specs->field_unsigned) ? asn_ulong2INTEGER(st, value) @@ -770,8 +770,8 @@ asn_dec_rval_t INTEGER_decode_uper(asn_codec_ctx_t *opt_codec_ctx, } asn_enc_rval_t INTEGER_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *sptr, asn_per_outp_t *po) + asn_per_constraints_t *constraints, + void *sptr, asn_per_outp_t *po) { asn_INTEGER_specifics_t *specs = (asn_INTEGER_specifics_t *)td->specifics; asn_enc_rval_t er; @@ -807,8 +807,8 @@ asn_enc_rval_t INTEGER_encode_uper(asn_TYPE_descriptor_t *td, inext = 1; } ASN_DEBUG("Value %lu (%02x/%d) lb %lu ub %lu %s", uval, - st->buf[0], st->size, ct->lower_bound, - ct->upper_bound, inext ? "ext" : "fix"); + st->buf[0], st->size, ct->lower_bound, + ct->upper_bound, inext ? "ext" : "fix"); value = uval; } else @@ -826,8 +826,8 @@ asn_enc_rval_t INTEGER_encode_uper(asn_TYPE_descriptor_t *td, inext = 1; } ASN_DEBUG("Value %ld (%02x/%d) lb %ld ub %ld %s", value, - st->buf[0], st->size, ct->lower_bound, - ct->upper_bound, inext ? "ext" : "fix"); + st->buf[0], st->size, ct->lower_bound, + ct->upper_bound, inext ? "ext" : "fix"); } if (ct->flags & APC_EXTENSIBLE) { @@ -856,7 +856,7 @@ asn_enc_rval_t INTEGER_encode_uper(asn_TYPE_descriptor_t *td, else { if (per_put_few_bits(po, value - ct->lower_bound, - ct->range_bits)) + ct->range_bits)) _ASN_ENCODE_FAILED; } _ASN_ENCODED_OK(er); @@ -913,12 +913,12 @@ int asn_INTEGER2long(const INTEGER_t *iptr, int64_t *lptr) { switch (*b) { - case 0x00: - if ((b[1] & 0x80) == 0) continue; - break; - case 0xff: - if ((b[1] & 0x80) != 0) continue; - break; + case 0x00: + if ((b[1] & 0x80) == 0) continue; + break; + case 0xff: + if ((b[1] & 0x80) != 0) continue; + break; } break; } @@ -1054,12 +1054,12 @@ int asn_long2INTEGER(INTEGER_t *st, int64_t value) { switch (*p) { - case 0x00: - if ((*(p + add) & 0x80) == 0) continue; - break; - case 0xff: - if ((*(p + add) & 0x80)) continue; - break; + case 0x00: + if ((*(p + add) & 0x80) == 0) continue; + break; + case 0xff: + if ((*(p + add) & 0x80)) continue; + break; } break; } diff --git a/src/core/libs/supl/asn-supl/IPAddress.c b/src/core/libs/supl/asn-supl/IPAddress.c index d6acf8163..4ace2a92f 100644 --- a/src/core/libs/supl/asn-supl/IPAddress.c +++ b/src/core/libs/supl/asn-supl/IPAddress.c @@ -7,9 +7,9 @@ #include "IPAddress.h" static int memb_ipv4Address_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const OCTET_STRING_t *st = (const OCTET_STRING_t *)sptr; size_t size; @@ -17,7 +17,7 @@ static int memb_ipv4Address_constraint_1(asn_TYPE_descriptor_t *td, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -31,15 +31,15 @@ static int memb_ipv4Address_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_ipv6Address_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const OCTET_STRING_t *st = (const OCTET_STRING_t *)sptr; size_t size; @@ -47,7 +47,7 @@ static int memb_ipv6Address_constraint_1(asn_TYPE_descriptor_t *td, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -61,7 +61,7 @@ static int memb_ipv6Address_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -86,13 +86,13 @@ static asn_per_constraints_t ASN_PER_TYPE_IP_ADDRESS_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_IPAddress_1[] = { {ATF_NOFLAGS, 0, offsetof(struct IPAddress, choice.ipv4Address), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_OCTET_STRING, memb_ipv4Address_constraint_1, - &ASN_PER_MEMB_IPV4_ADDRESS_CONSTR_2, 0, "ipv4Address"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_OCTET_STRING, memb_ipv4Address_constraint_1, + &ASN_PER_MEMB_IPV4_ADDRESS_CONSTR_2, 0, "ipv4Address"}, {ATF_NOFLAGS, 0, offsetof(struct IPAddress, choice.ipv6Address), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_OCTET_STRING, memb_ipv6Address_constraint_1, - &ASN_PER_MEMB_IPV6_ADDRESS_CONSTR_3, 0, "ipv6Address"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_OCTET_STRING, memb_ipv6Address_constraint_1, + &ASN_PER_MEMB_IPV6_ADDRESS_CONSTR_3, 0, "ipv6Address"}, }; static asn_TYPE_tag2member_t asn_MAP_IPAddress_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* ipv4Address at 41 */ diff --git a/src/core/libs/supl/asn-supl/KeyIdentity.c b/src/core/libs/supl/asn-supl/KeyIdentity.c index 5dd017009..344696cf1 100644 --- a/src/core/libs/supl/asn-supl/KeyIdentity.c +++ b/src/core/libs/supl/asn-supl/KeyIdentity.c @@ -7,7 +7,7 @@ #include "KeyIdentity.h" int KeyIdentity_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { const BIT_STRING_t *st = (const BIT_STRING_t *)sptr; size_t size; @@ -15,7 +15,7 @@ int KeyIdentity_constraint(asn_TYPE_descriptor_t *td, const void *sptr, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -37,7 +37,7 @@ int KeyIdentity_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -64,73 +64,73 @@ static void KeyIdentity_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void KeyIdentity_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { KeyIdentity_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int KeyIdentity_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { KeyIdentity_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t KeyIdentity_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { KeyIdentity_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t KeyIdentity_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { KeyIdentity_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t KeyIdentity_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, const char *opt_mname, + const void *bufptr, size_t size) { KeyIdentity_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t KeyIdentity_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { KeyIdentity_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t KeyIdentity_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { KeyIdentity_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t KeyIdentity_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { KeyIdentity_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-supl/KeyIdentity4.c b/src/core/libs/supl/asn-supl/KeyIdentity4.c index 54cb9cc84..9c4533021 100644 --- a/src/core/libs/supl/asn-supl/KeyIdentity4.c +++ b/src/core/libs/supl/asn-supl/KeyIdentity4.c @@ -7,8 +7,8 @@ #include "KeyIdentity4.h" int KeyIdentity4_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const BIT_STRING_t *st = (const BIT_STRING_t *)sptr; size_t size; @@ -16,7 +16,7 @@ int KeyIdentity4_constraint(asn_TYPE_descriptor_t *td, const void *sptr, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -38,7 +38,7 @@ int KeyIdentity4_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -65,74 +65,74 @@ static void KeyIdentity4_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void KeyIdentity4_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { KeyIdentity4_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int KeyIdentity4_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { KeyIdentity4_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t KeyIdentity4_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { KeyIdentity4_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t KeyIdentity4_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { KeyIdentity4_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t KeyIdentity4_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, const char *opt_mname, + const void *bufptr, size_t size) { KeyIdentity4_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t KeyIdentity4_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { KeyIdentity4_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t KeyIdentity4_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { KeyIdentity4_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t KeyIdentity4_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { KeyIdentity4_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-supl/LocationId.c b/src/core/libs/supl/asn-supl/LocationId.c index c514749eb..7a688710b 100644 --- a/src/core/libs/supl/asn-supl/LocationId.c +++ b/src/core/libs/supl/asn-supl/LocationId.c @@ -8,15 +8,15 @@ static asn_TYPE_member_t asn_MBR_LocationId_1[] = { {ATF_NOFLAGS, 0, offsetof(struct LocationId, cellInfo), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), +1, /* EXPLICIT tag at current level */ - &asn_DEF_CellInfo, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "cellInfo"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), +1, /* EXPLICIT tag at current level */ + &asn_DEF_CellInfo, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "cellInfo"}, {ATF_NOFLAGS, 0, offsetof(struct LocationId, status), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Status, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "status"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Status, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "status"}, }; static ber_tlv_tag_t asn_DEF_LocationId_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-supl/MAC.c b/src/core/libs/supl/asn-supl/MAC.c index cc49e7f01..2de0aaf7d 100644 --- a/src/core/libs/supl/asn-supl/MAC.c +++ b/src/core/libs/supl/asn-supl/MAC.c @@ -7,7 +7,7 @@ #include "MAC.h" int MAC_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { const BIT_STRING_t *st = (const BIT_STRING_t *)sptr; size_t size; @@ -15,7 +15,7 @@ int MAC_constraint(asn_TYPE_descriptor_t *td, const void *sptr, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -37,7 +37,7 @@ int MAC_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -70,60 +70,60 @@ void MAC_free(asn_TYPE_descriptor_t *td, void *struct_ptr, int contents_only) } int MAC_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { MAC_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t MAC_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, int tag_mode) { MAC_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t MAC_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { MAC_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t MAC_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { MAC_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t MAC_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { MAC_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t MAC_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { MAC_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t MAC_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { MAC_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); @@ -152,7 +152,7 @@ asn_TYPE_descriptor_t asn_DEF_MAC = { 0, /* Use generic outmost tag fetcher */ asn_DEF_MAC_tags_1, sizeof(asn_DEF_MAC_tags_1) / sizeof(asn_DEF_MAC_tags_1[0]), /* 1 */ - asn_DEF_MAC_tags_1, /* Same as above */ + asn_DEF_MAC_tags_1, /* Same as above */ sizeof(asn_DEF_MAC_tags_1) / sizeof(asn_DEF_MAC_tags_1[0]), /* 1 */ &ASN_PER_TYPE_MAC_CONSTR_1, 0, diff --git a/src/core/libs/supl/asn-supl/MeasuredResults.c b/src/core/libs/supl/asn-supl/MeasuredResults.c index aa9256e56..67c294621 100644 --- a/src/core/libs/supl/asn-supl/MeasuredResults.c +++ b/src/core/libs/supl/asn-supl/MeasuredResults.c @@ -8,23 +8,23 @@ static asn_TYPE_member_t asn_MBR_MeasuredResults_1[] = { {ATF_POINTER, 3, offsetof(struct MeasuredResults, frequencyInfo), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_FrequencyInfo, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "frequencyInfo"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_FrequencyInfo, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "frequencyInfo"}, {ATF_POINTER, 2, offsetof(struct MeasuredResults, utra_CarrierRSSI), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_UTRA_CarrierRSSI, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "utra-CarrierRSSI"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_UTRA_CarrierRSSI, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "utra-CarrierRSSI"}, {ATF_POINTER, 1, offsetof(struct MeasuredResults, cellMeasuredResultsList), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_CellMeasuredResultsList, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "cellMeasuredResultsList"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_CellMeasuredResultsList, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "cellMeasuredResultsList"}, }; static int asn_MAP_MeasuredResults_oms_1[] = {0, 1, 2}; static ber_tlv_tag_t asn_DEF_MeasuredResults_tags_1[] = { @@ -33,7 +33,7 @@ static asn_TYPE_tag2member_t asn_MAP_MeasuredResults_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* frequencyInfo at 148 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0}, /* utra-CarrierRSSI at 149 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, - 0} /* cellMeasuredResultsList at 150 */ + 0} /* cellMeasuredResultsList at 150 */ }; static asn_SEQUENCE_specifics_t asn_SPC_MeasuredResults_specs_1 = { sizeof(struct MeasuredResults), @@ -65,7 +65,7 @@ asn_TYPE_descriptor_t asn_DEF_MeasuredResults = { asn_DEF_MeasuredResults_tags_1, /* Same as above */ sizeof(asn_DEF_MeasuredResults_tags_1) / sizeof(asn_DEF_MeasuredResults_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_MeasuredResults_1, 3, /* Elements count */ &asn_SPC_MeasuredResults_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-supl/MeasuredResults.h b/src/core/libs/supl/asn-supl/MeasuredResults.h index 029f4270e..72efe8f64 100644 --- a/src/core/libs/supl/asn-supl/MeasuredResults.h +++ b/src/core/libs/supl/asn-supl/MeasuredResults.h @@ -41,8 +41,8 @@ extern "C" #endif /* Referred external types */ -#include "FrequencyInfo.h" #include "CellMeasuredResultsList.h" +#include "FrequencyInfo.h" #endif /* _MeasuredResults_H_ */ #include diff --git a/src/core/libs/supl/asn-supl/MeasuredResultsList.c b/src/core/libs/supl/asn-supl/MeasuredResultsList.c index 09ba72bed..417c2125b 100644 --- a/src/core/libs/supl/asn-supl/MeasuredResultsList.c +++ b/src/core/libs/supl/asn-supl/MeasuredResultsList.c @@ -14,10 +14,10 @@ static asn_per_constraints_t ASN_PER_TYPE_MEASURED_RESULTS_LIST_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_MeasuredResultsList_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_MeasuredResults, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_MeasuredResults, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_MeasuredResultsList_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-supl/NMR.c b/src/core/libs/supl/asn-supl/NMR.c index 4366349f3..317cb512a 100644 --- a/src/core/libs/supl/asn-supl/NMR.c +++ b/src/core/libs/supl/asn-supl/NMR.c @@ -14,9 +14,9 @@ static asn_per_constraints_t ASN_PER_TYPE_NMR_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_NMR_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_NMRelement, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_NMRelement, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_NMR_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -39,7 +39,7 @@ asn_TYPE_descriptor_t asn_DEF_NMR = { 0, /* Use generic outmost tag fetcher */ asn_DEF_NMR_tags_1, sizeof(asn_DEF_NMR_tags_1) / sizeof(asn_DEF_NMR_tags_1[0]), /* 1 */ - asn_DEF_NMR_tags_1, /* Same as above */ + asn_DEF_NMR_tags_1, /* Same as above */ sizeof(asn_DEF_NMR_tags_1) / sizeof(asn_DEF_NMR_tags_1[0]), /* 1 */ &ASN_PER_TYPE_NMR_CONSTR_1, asn_MBR_NMR_1, diff --git a/src/core/libs/supl/asn-supl/NMRelement.c b/src/core/libs/supl/asn-supl/NMRelement.c index df1ca1d11..b29a5eb1e 100644 --- a/src/core/libs/supl/asn-supl/NMRelement.c +++ b/src/core/libs/supl/asn-supl/NMRelement.c @@ -7,15 +7,15 @@ #include "NMRelement.h" static int memb_aRFCN_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,21 +29,21 @@ static int memb_aRFCN_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_bSIC_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -57,21 +57,21 @@ static int memb_bSIC_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_rxLev_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -85,7 +85,7 @@ static int memb_rxLev_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -110,17 +110,17 @@ static asn_per_constraints_t ASN_PER_MEMB_RX_LEV_CONSTR_4 = { }; static asn_TYPE_member_t asn_MBR_NMRelement_1[] = { {ATF_NOFLAGS, 0, offsetof(struct NMRelement, aRFCN), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_aRFCN_constraint_1, - &ASN_PER_MEMB_A_RFCN_CONSTR_2, 0, "aRFCN"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_aRFCN_constraint_1, + &ASN_PER_MEMB_A_RFCN_CONSTR_2, 0, "aRFCN"}, {ATF_NOFLAGS, 0, offsetof(struct NMRelement, bSIC), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_bSIC_constraint_1, - &ASN_PER_MEMB_B_SIC_CONSTR_3, 0, "bSIC"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_bSIC_constraint_1, + &ASN_PER_MEMB_B_SIC_CONSTR_3, 0, "bSIC"}, {ATF_NOFLAGS, 0, offsetof(struct NMRelement, rxLev), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_rxLev_constraint_1, - &ASN_PER_MEMB_RX_LEV_CONSTR_4, 0, "rxLev"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_rxLev_constraint_1, + &ASN_PER_MEMB_RX_LEV_CONSTR_4, 0, "rxLev"}, }; static ber_tlv_tag_t asn_DEF_NMRelement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-supl/NativeEnumerated.c b/src/core/libs/supl/asn-supl/NativeEnumerated.c index dd4d3f235..1f6394e52 100644 --- a/src/core/libs/supl/asn-supl/NativeEnumerated.c +++ b/src/core/libs/supl/asn-supl/NativeEnumerated.c @@ -9,8 +9,8 @@ * implementation deals with the standard (machine-specific) representation * of them instead of using the platform-independent buffer. */ -#include #include +#include /* * NativeEnumerated basic type description. @@ -43,10 +43,10 @@ asn_TYPE_descriptor_t asn_DEF_NativeEnumerated = { }; asn_enc_rval_t NativeEnumerated_encode_xer(asn_TYPE_descriptor_t *td, - void *sptr, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *sptr, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { asn_INTEGER_specifics_t *specs = (asn_INTEGER_specifics_t *)td->specifics; asn_enc_rval_t er; @@ -79,9 +79,9 @@ asn_enc_rval_t NativeEnumerated_encode_xer(asn_TYPE_descriptor_t *td, } asn_dec_rval_t NativeEnumerated_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd) { asn_INTEGER_specifics_t *specs = (asn_INTEGER_specifics_t *)td->specifics; asn_dec_rval_t rval = {RC_OK, 0}; @@ -150,8 +150,8 @@ static int NativeEnumerated__compar_value2enum(const void *ap, const void *bp) } asn_enc_rval_t NativeEnumerated_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *sptr, asn_per_outp_t *po) + asn_per_constraints_t *constraints, + void *sptr, asn_per_outp_t *po) { asn_INTEGER_specifics_t *specs = (asn_INTEGER_specifics_t *)td->specifics; asn_enc_rval_t er; @@ -181,7 +181,7 @@ asn_enc_rval_t NativeEnumerated_encode_uper(asn_TYPE_descriptor_t *td, key.nat_value = native; kf = bsearch(&key, specs->value2enum, specs->map_count, sizeof(key), - NativeEnumerated__compar_value2enum); + NativeEnumerated__compar_value2enum); if (!kf) { ASN_DEBUG("No element corresponds to %ld", native); @@ -217,8 +217,8 @@ asn_enc_rval_t NativeEnumerated_encode_uper(asn_TYPE_descriptor_t *td, * X.691, #10.6: normally small non-negative whole number; */ ASN_DEBUG("value = %ld, ext = %d, inext = %d, res = %ld", value, - specs->extension, inext, - value - (inext ? (specs->extension - 1) : 0)); + specs->extension, inext, + value - (inext ? (specs->extension - 1) : 0)); if (uper_put_nsnnwn(po, value - (inext ? (specs->extension - 1) : 0))) _ASN_ENCODE_FAILED; diff --git a/src/core/libs/supl/asn-supl/NativeInteger.c b/src/core/libs/supl/asn-supl/NativeInteger.c index 675850bda..8d6b14b27 100644 --- a/src/core/libs/supl/asn-supl/NativeInteger.c +++ b/src/core/libs/supl/asn-supl/NativeInteger.c @@ -10,8 +10,8 @@ * implementation deals with the standard (machine-specific) representation * of them instead of using the platform-independent buffer. */ -#include #include +#include /* * NativeInteger basic type description. @@ -45,9 +45,9 @@ asn_TYPE_descriptor_t asn_DEF_NativeInteger = { * Decode INTEGER type. */ asn_dec_rval_t NativeInteger_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **nint_ptr, const void *buf_ptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **nint_ptr, const void *buf_ptr, + size_t size, int tag_mode) { asn_INTEGER_specifics_t *specs = (asn_INTEGER_specifics_t *)td->specifics; int64_t *native = (int64_t *)*nint_ptr; @@ -74,7 +74,7 @@ asn_dec_rval_t NativeInteger_decode_ber(asn_codec_ctx_t *opt_codec_ctx, * Check tags. */ rval = ber_check_tags(opt_codec_ctx, td, 0, buf_ptr, size, tag_mode, 0, - &length, 0); + &length, 0); if (rval.code != RC_OK) return rval; ASN_DEBUG("%s length is %d bytes", td->name, (int)length); @@ -125,7 +125,7 @@ asn_dec_rval_t NativeInteger_decode_ber(asn_codec_ctx_t *opt_codec_ctx, rval.consumed += length; ASN_DEBUG("Took %ld/%ld bytes to encode %s (%ld)", (long)rval.consumed, - (long)length, td->name, (long)*native); + (long)length, td->name, (long)*native); return rval; } @@ -134,9 +134,9 @@ asn_dec_rval_t NativeInteger_decode_ber(asn_codec_ctx_t *opt_codec_ctx, * Encode the NativeInteger using the standard INTEGER type DER encoder. */ asn_enc_rval_t NativeInteger_encode_der(asn_TYPE_descriptor_t *sd, void *ptr, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { uint64_t native = *(uint64_t *)ptr; /* Disable sign ext. */ asn_enc_rval_t erval; @@ -173,9 +173,9 @@ asn_enc_rval_t NativeInteger_encode_der(asn_TYPE_descriptor_t *sd, void *ptr, * Decode the chunk of XML text encoding INTEGER. */ asn_dec_rval_t NativeInteger_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **sptr, - const char *opt_mname, - const void *buf_ptr, size_t size) + asn_TYPE_descriptor_t *td, void **sptr, + const char *opt_mname, + const void *buf_ptr, size_t size) { asn_INTEGER_specifics_t *specs = (asn_INTEGER_specifics_t *)td->specifics; asn_dec_rval_t rval; @@ -191,7 +191,7 @@ asn_dec_rval_t NativeInteger_decode_xer(asn_codec_ctx_t *opt_codec_ctx, memset(&st, 0, sizeof(st)); rval = INTEGER_decode_xer(opt_codec_ctx, td, &st_ptr, opt_mname, buf_ptr, - size); + size); if (rval.code == RC_OK) { int64_t l; @@ -221,10 +221,10 @@ asn_dec_rval_t NativeInteger_decode_xer(asn_codec_ctx_t *opt_codec_ctx, } asn_enc_rval_t NativeInteger_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, - int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { asn_INTEGER_specifics_t *specs = (asn_INTEGER_specifics_t *)td->specifics; char scratch[32]; /* Enough for 64-bit int */ @@ -238,7 +238,7 @@ asn_enc_rval_t NativeInteger_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, er.encoded = snprintf(scratch, sizeof(scratch), - (specs && specs->field_unsigned) ? "%lu" : "%ld", *native); + (specs && specs->field_unsigned) ? "%lu" : "%ld", *native); if (er.encoded <= 0 || (size_t)er.encoded >= sizeof(scratch) || cb(scratch, er.encoded, app_key) < 0) _ASN_ENCODE_FAILED; @@ -247,9 +247,9 @@ asn_enc_rval_t NativeInteger_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, } asn_dec_rval_t NativeInteger_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd) { asn_INTEGER_specifics_t *specs = (asn_INTEGER_specifics_t *)td->specifics; asn_dec_rval_t rval; @@ -283,8 +283,8 @@ asn_dec_rval_t NativeInteger_decode_uper(asn_codec_ctx_t *opt_codec_ctx, } asn_enc_rval_t NativeInteger_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *sptr, asn_per_outp_t *po) + asn_per_constraints_t *constraints, + void *sptr, asn_per_outp_t *po) { asn_INTEGER_specifics_t *specs = (asn_INTEGER_specifics_t *)td->specifics; asn_enc_rval_t er; @@ -310,7 +310,7 @@ asn_enc_rval_t NativeInteger_encode_uper(asn_TYPE_descriptor_t *td, * INTEGER specific human-readable output. */ int NativeInteger_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { asn_INTEGER_specifics_t *specs = (asn_INTEGER_specifics_t *)td->specifics; const long *native = (const long *)sptr; @@ -323,8 +323,8 @@ int NativeInteger_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, if (native) { ret = snprintf(scratch, sizeof(scratch), - (specs && specs->field_unsigned) ? "%lu" : "%ld", - *native); + (specs && specs->field_unsigned) ? "%lu" : "%ld", + *native); assert(ret > 0 && (size_t)ret < sizeof(scratch)); return (cb(scratch, ret, app_key) < 0) ? -1 : 0; } @@ -339,7 +339,7 @@ void NativeInteger_free(asn_TYPE_descriptor_t *td, void *ptr, int contents_only) if (!td || !ptr) return; ASN_DEBUG("Freeing %s as INTEGER (%d, %p, Native)", td->name, contents_only, - ptr); + ptr); if (!contents_only) { diff --git a/src/core/libs/supl/asn-supl/NativeInteger.h b/src/core/libs/supl/asn-supl/NativeInteger.h index 14311ae57..0fe9afff4 100644 --- a/src/core/libs/supl/asn-supl/NativeInteger.h +++ b/src/core/libs/supl/asn-supl/NativeInteger.h @@ -12,8 +12,8 @@ #ifndef _NativeInteger_H_ #define _NativeInteger_H_ -#include #include +#include #ifdef __cplusplus extern "C" diff --git a/src/core/libs/supl/asn-supl/Notification.c b/src/core/libs/supl/asn-supl/Notification.c index 0b054927a..18ebe0706 100644 --- a/src/core/libs/supl/asn-supl/Notification.c +++ b/src/core/libs/supl/asn-supl/Notification.c @@ -7,9 +7,9 @@ #include "Notification.h" static int memb_requestorId_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const OCTET_STRING_t *st = (const OCTET_STRING_t *)sptr; size_t size; @@ -17,7 +17,7 @@ static int memb_requestorId_constraint_1(asn_TYPE_descriptor_t *td, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -31,15 +31,15 @@ static int memb_requestorId_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_clientName_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const OCTET_STRING_t *st = (const OCTET_STRING_t *)sptr; size_t size; @@ -47,7 +47,7 @@ static int memb_clientName_constraint_1(asn_TYPE_descriptor_t *td, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -61,7 +61,7 @@ static int memb_clientName_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -80,37 +80,37 @@ static asn_per_constraints_t ASN_PER_MEMB_CLIENT_NAME_CONSTR_6 = { }; static asn_TYPE_member_t asn_MBR_Notification_1[] = { {ATF_NOFLAGS, 0, offsetof(struct Notification, notificationType), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NotificationType, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "notificationType"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NotificationType, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "notificationType"}, {ATF_POINTER, 5, offsetof(struct Notification, encodingType), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_EncodingType, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "encodingType"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_EncodingType, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "encodingType"}, {ATF_POINTER, 4, offsetof(struct Notification, requestorId), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_OCTET_STRING, memb_requestorId_constraint_1, - &ASN_PER_MEMB_REQUESTOR_ID_CONSTR_4, 0, "requestorId"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_OCTET_STRING, memb_requestorId_constraint_1, + &ASN_PER_MEMB_REQUESTOR_ID_CONSTR_4, 0, "requestorId"}, {ATF_POINTER, 3, offsetof(struct Notification, requestorIdType), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_FormatIndicator, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "requestorIdType"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_FormatIndicator, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "requestorIdType"}, {ATF_POINTER, 2, offsetof(struct Notification, clientName), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_OCTET_STRING, memb_clientName_constraint_1, - &ASN_PER_MEMB_CLIENT_NAME_CONSTR_6, 0, "clientName"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_OCTET_STRING, memb_clientName_constraint_1, + &ASN_PER_MEMB_CLIENT_NAME_CONSTR_6, 0, "clientName"}, {ATF_POINTER, 1, offsetof(struct Notification, clientNameType), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_FormatIndicator, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "clientNameType"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_FormatIndicator, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "clientNameType"}, }; static int asn_MAP_Notification_oms_1[] = {1, 2, 3, 4, 5}; static ber_tlv_tag_t asn_DEF_Notification_tags_1[] = { diff --git a/src/core/libs/supl/asn-supl/Notification.h b/src/core/libs/supl/asn-supl/Notification.h index 4cc4f1f65..bd1df0c6d 100644 --- a/src/core/libs/supl/asn-supl/Notification.h +++ b/src/core/libs/supl/asn-supl/Notification.h @@ -10,10 +10,10 @@ #include /* Including external dependencies */ -#include "NotificationType.h" #include "EncodingType.h" -#include #include "FormatIndicator.h" +#include "NotificationType.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-supl/NotificationType.c b/src/core/libs/supl/asn-supl/NotificationType.c index c21e1a09e..5681ee170 100644 --- a/src/core/libs/supl/asn-supl/NotificationType.c +++ b/src/core/libs/supl/asn-supl/NotificationType.c @@ -7,8 +7,8 @@ #include "NotificationType.h" int NotificationType_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { /* Replace with underlying type checker */ td->check_constraints = asn_DEF_ENUMERATED.check_constraints; @@ -40,76 +40,76 @@ static void NotificationType_1_inherit_TYPE_descriptor( } void NotificationType_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { NotificationType_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int NotificationType_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, + void *app_key) { NotificationType_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t NotificationType_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { NotificationType_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t NotificationType_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { NotificationType_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t NotificationType_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { NotificationType_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t NotificationType_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { NotificationType_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t NotificationType_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { NotificationType_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t NotificationType_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { NotificationType_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-supl/OCTET_STRING.c b/src/core/libs/supl/asn-supl/OCTET_STRING.c index e66360994..b092caadf 100644 --- a/src/core/libs/supl/asn-supl/OCTET_STRING.c +++ b/src/core/libs/supl/asn-supl/OCTET_STRING.c @@ -3,9 +3,9 @@ * All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ -#include -#include #include /* for .bits_unused member */ +#include +#include #include /* @@ -182,9 +182,9 @@ static struct _stack *_new_stack() * Decode OCTET STRING type. */ asn_dec_rval_t OCTET_STRING_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **sptr, - const void *buf_ptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, void **sptr, + const void *buf_ptr, size_t size, + int tag_mode) { asn_OCTET_STRING_specifics_t *specs = td->specifics ? (asn_OCTET_STRING_specifics_t *)td->specifics @@ -217,351 +217,351 @@ asn_dec_rval_t OCTET_STRING_decode_ber(asn_codec_ctx_t *opt_codec_ctx, switch (ctx->phase) { - case 0: - /* + case 0: + /* * Check tags. */ - rval = ber_check_tags(opt_codec_ctx, td, ctx, buf_ptr, size, - tag_mode, -1, &ctx->left, &tlv_constr); - if (rval.code != RC_OK) return rval; + rval = ber_check_tags(opt_codec_ctx, td, ctx, buf_ptr, size, + tag_mode, -1, &ctx->left, &tlv_constr); + if (rval.code != RC_OK) return rval; - if (tlv_constr) - { - /* + if (tlv_constr) + { + /* * Complex operation, requires stack of expectations. */ - ctx->ptr = _new_stack(); - if (ctx->ptr) - { - stck = (struct _stack *)ctx->ptr; - } - else - { - RETURN(RC_FAIL); - } - } - else - { - /* + ctx->ptr = _new_stack(); + if (ctx->ptr) + { + stck = (struct _stack *)ctx->ptr; + } + else + { + RETURN(RC_FAIL); + } + } + else + { + /* * Jump into stackless primitive decoding. */ - _CH_PHASE(ctx, 3); - if (type_variant == ASN_OSUBV_ANY && tag_mode != 1) - APPEND(buf_ptr, rval.consumed); - ADVANCE(rval.consumed); - goto phase3; - } + _CH_PHASE(ctx, 3); + if (type_variant == ASN_OSUBV_ANY && tag_mode != 1) + APPEND(buf_ptr, rval.consumed); + ADVANCE(rval.consumed); + goto phase3; + } - NEXT_PHASE(ctx); - /* Fall through */ - case 1: - phase1: - /* + NEXT_PHASE(ctx); + /* Fall through */ + case 1: + phase1: + /* * Fill the stack with expectations. */ - stck = (struct _stack *)ctx->ptr; - sel = stck->cur_ptr; - do - { - ber_tlv_tag_t tlv_tag; - ber_tlv_len_t tlv_len; - ber_tlv_tag_t expected_tag; - ssize_t tl; - ssize_t ll; - ssize_t tlvl; - /* This one works even if (sel->left == -1) */ - ssize_t Left = - ((!sel || (size_t)sel->left >= size) ? (ssize_t)size - : sel->left); - - ASN_DEBUG("%p, s->l=%ld, s->wn=%ld, s->g=%ld\n", sel, - (sel ? sel->left : 0), - (long)(sel ? sel->want_nulls : 0), - (sel ? sel->got : 0)); - if (sel && sel->left <= 0 && sel->want_nulls == 0) - { - if (sel->prev) - { - struct _stack_el *prev = sel->prev; - if (prev->left != -1) - { - if (prev->left < sel->got) - RETURN(RC_FAIL); - prev->left -= sel->got; - } - prev->got += sel->got; - sel = stck->cur_ptr = prev; - if (!sel) break; - tlv_constr = 1; - continue; - } - else - { - sel = stck->cur_ptr = 0; - break; /* Nothing to wait */ - } - } - - tl = ber_fetch_tag(buf_ptr, Left, &tlv_tag); - ASN_DEBUG( - "fetch tag(size=%ld,L=%ld), %sstack, left=%ld, " - "wn=%ld, " - "tl=%ld", - (long)size, (long)Left, sel ? "" : "!", - (sel ? sel->left : 0), - (long)(sel ? sel->want_nulls : 0), (long)tl); - switch (tl) - { - case -1: - RETURN(RC_FAIL); - case 0: - RETURN(RC_WMORE); - } - - tlv_constr = BER_TLV_CONSTRUCTED(buf_ptr); - - ll = ber_fetch_length(tlv_constr, - (const char *)buf_ptr + tl, - Left - tl, &tlv_len); - ASN_DEBUG( - "Got tag=%s, tc=%d, left=%ld, tl=%ld, len=%ld, " - "ll=%ld", - ber_tlv_tag_string(tlv_tag), tlv_constr, (long)Left, - (long)tl, (long)tlv_len, (long)ll); - switch (ll) - { - case -1: - RETURN(RC_FAIL); - case 0: - RETURN(RC_WMORE); - } - - if (sel && sel->want_nulls && - ((const uint8_t *)buf_ptr)[0] == 0 && - ((const uint8_t *)buf_ptr)[1] == 0) - { - ASN_DEBUG("Eat EOC; wn=%d--", sel->want_nulls); - - if (type_variant == ASN_OSUBV_ANY && - (tag_mode != 1 || sel->cont_level)) - APPEND("\0\0", 2); - - ADVANCE(2); - sel->got += 2; - if (sel->left != -1) - { - sel->left -= - 2; /* assert(sel->left >= 2) */ - } - - sel->want_nulls--; - if (sel->want_nulls == 0) - { - /* Move to the next expectation */ - sel->left = 0; - tlv_constr = 1; - } - - continue; - } - - /* - * Set up expected tags, - * depending on ASN.1 type being decoded. - */ - switch (type_variant) - { - case ASN_OSUBV_BIT: - /* X.690: 8.6.4.1, NOTE 2 */ - /* Fall through */ - case ASN_OSUBV_STR: - default: - if (sel) - { - int level = sel->cont_level; - if (level < td->all_tags_count) - { - expected_tag = - td->all_tags[level]; - break; - } - else if (td->all_tags_count) - { - expected_tag = - td->all_tags - [td->all_tags_count - - 1]; - break; - } - /* else, Fall through */ - } - /* Fall through */ - case ASN_OSUBV_ANY: - expected_tag = tlv_tag; - break; - } - - if (tlv_tag != expected_tag) - { - char buf[2][32]; - ber_tlv_tag_snprint(tlv_tag, buf[0], - sizeof(buf[0])); - ber_tlv_tag_snprint( - td->tags[td->tags_count - 1], buf[1], - sizeof(buf[1])); - ASN_DEBUG( - "Tag does not match expectation: %s != %s", - buf[0], buf[1]); - RETURN(RC_FAIL); - } - - tlvl = - tl + ll; /* Combined length of T and L encoding */ - if ((tlv_len + tlvl) < 0) - { - /* tlv_len value is too big */ - ASN_DEBUG( - "TLV encoding + length (%ld) is too big", - (long)tlv_len); - RETURN(RC_FAIL); - } - - /* - * Append a new expectation. - */ - sel = OS__add_stack_el(stck); - if (!sel) RETURN(RC_FAIL); - - sel->tag = tlv_tag; - - sel->want_nulls = (tlv_len == -1); - if (sel->prev && sel->prev->left != -1) - { - /* Check that the parent frame is big enough */ - if (sel->prev->left < - tlvl + (tlv_len == -1 ? 0 : tlv_len)) - RETURN(RC_FAIL); - if (tlv_len == -1) - sel->left = sel->prev->left - tlvl; - else - sel->left = tlv_len; - } - else - { - sel->left = tlv_len; - } - if (type_variant == ASN_OSUBV_ANY && - (tag_mode != 1 || sel->cont_level)) - APPEND(buf_ptr, tlvl); - sel->got += tlvl; - ADVANCE(tlvl); - - ASN_DEBUG("+EXPECT2 got=%ld left=%ld, wn=%d, clvl=%d", - (long)sel->got, (long)sel->left, - sel->want_nulls, sel->cont_level); - } - while (tlv_constr); - if (sel == NULL) - { - /* Finished operation, "phase out" */ - ASN_DEBUG("Phase out"); - _CH_PHASE(ctx, +3); - break; - } - - NEXT_PHASE(ctx); - /* Fall through */ - case 2: - stck = (struct _stack *)ctx->ptr; - sel = stck->cur_ptr; - ASN_DEBUG("Phase 2: Need %ld bytes, size=%ld, alrg=%ld, wn=%d", - (long)sel->left, (long)size, (long)sel->got, - sel->want_nulls); + stck = (struct _stack *)ctx->ptr; + sel = stck->cur_ptr; + do { - ber_tlv_len_t len; + ber_tlv_tag_t tlv_tag; + ber_tlv_len_t tlv_len; + ber_tlv_tag_t expected_tag; + ssize_t tl; + ssize_t ll; + ssize_t tlvl; + /* This one works even if (sel->left == -1) */ + ssize_t Left = + ((!sel || (size_t)sel->left >= size) ? (ssize_t)size + : sel->left); - assert(sel->left >= 0); - - len = ((ber_tlv_len_t)size < sel->left) - ? (ber_tlv_len_t)size - : sel->left; - if (len > 0) + ASN_DEBUG("%p, s->l=%ld, s->wn=%ld, s->g=%ld\n", sel, + (sel ? sel->left : 0), + (long)(sel ? sel->want_nulls : 0), + (sel ? sel->got : 0)); + if (sel && sel->left <= 0 && sel->want_nulls == 0) { - if (type_variant == ASN_OSUBV_BIT && - sel->bits_chopped == 0) + if (sel->prev) { - /* Put the unused-bits-octet away */ - st->bits_unused = *(const uint8_t *)buf_ptr; - APPEND(((const char *)buf_ptr + 1), - (len - 1)); - sel->bits_chopped = 1; + struct _stack_el *prev = sel->prev; + if (prev->left != -1) + { + if (prev->left < sel->got) + RETURN(RC_FAIL); + prev->left -= sel->got; + } + prev->got += sel->got; + sel = stck->cur_ptr = prev; + if (!sel) break; + tlv_constr = 1; + continue; } else { - APPEND(buf_ptr, len); + sel = stck->cur_ptr = 0; + break; /* Nothing to wait */ } - ADVANCE(len); - sel->left -= len; - sel->got += len; } - if (sel->left) + tl = ber_fetch_tag(buf_ptr, Left, &tlv_tag); + ASN_DEBUG( + "fetch tag(size=%ld,L=%ld), %sstack, left=%ld, " + "wn=%ld, " + "tl=%ld", + (long)size, (long)Left, sel ? "" : "!", + (sel ? sel->left : 0), + (long)(sel ? sel->want_nulls : 0), (long)tl); + switch (tl) { - ASN_DEBUG("OS left %ld, size = %ld, wn=%d\n", - (long)sel->left, (long)size, - sel->want_nulls); + case -1: + RETURN(RC_FAIL); + case 0: RETURN(RC_WMORE); } - PREV_PHASE(ctx); - goto phase1; - } - break; - case 3: - phase3: - /* - * Primitive form, no stack required. - */ - assert(ctx->left >= 0); + tlv_constr = BER_TLV_CONSTRUCTED(buf_ptr); - if (size < (size_t)ctx->left) + ll = ber_fetch_length(tlv_constr, + (const char *)buf_ptr + tl, + Left - tl, &tlv_len); + ASN_DEBUG( + "Got tag=%s, tc=%d, left=%ld, tl=%ld, len=%ld, " + "ll=%ld", + ber_tlv_tag_string(tlv_tag), tlv_constr, (long)Left, + (long)tl, (long)tlv_len, (long)ll); + switch (ll) + { + case -1: + RETURN(RC_FAIL); + case 0: + RETURN(RC_WMORE); + } + + if (sel && sel->want_nulls && + ((const uint8_t *)buf_ptr)[0] == 0 && + ((const uint8_t *)buf_ptr)[1] == 0) + { + ASN_DEBUG("Eat EOC; wn=%d--", sel->want_nulls); + + if (type_variant == ASN_OSUBV_ANY && + (tag_mode != 1 || sel->cont_level)) + APPEND("\0\0", 2); + + ADVANCE(2); + sel->got += 2; + if (sel->left != -1) + { + sel->left -= + 2; /* assert(sel->left >= 2) */ + } + + sel->want_nulls--; + if (sel->want_nulls == 0) + { + /* Move to the next expectation */ + sel->left = 0; + tlv_constr = 1; + } + + continue; + } + + /* + * Set up expected tags, + * depending on ASN.1 type being decoded. + */ + switch (type_variant) + { + case ASN_OSUBV_BIT: + /* X.690: 8.6.4.1, NOTE 2 */ + /* Fall through */ + case ASN_OSUBV_STR: + default: + if (sel) + { + int level = sel->cont_level; + if (level < td->all_tags_count) + { + expected_tag = + td->all_tags[level]; + break; + } + else if (td->all_tags_count) + { + expected_tag = + td->all_tags + [td->all_tags_count - + 1]; + break; + } + /* else, Fall through */ + } + /* Fall through */ + case ASN_OSUBV_ANY: + expected_tag = tlv_tag; + break; + } + + if (tlv_tag != expected_tag) + { + char buf[2][32]; + ber_tlv_tag_snprint(tlv_tag, buf[0], + sizeof(buf[0])); + ber_tlv_tag_snprint( + td->tags[td->tags_count - 1], buf[1], + sizeof(buf[1])); + ASN_DEBUG( + "Tag does not match expectation: %s != %s", + buf[0], buf[1]); + RETURN(RC_FAIL); + } + + tlvl = + tl + ll; /* Combined length of T and L encoding */ + if ((tlv_len + tlvl) < 0) + { + /* tlv_len value is too big */ + ASN_DEBUG( + "TLV encoding + length (%ld) is too big", + (long)tlv_len); + RETURN(RC_FAIL); + } + + /* + * Append a new expectation. + */ + sel = OS__add_stack_el(stck); + if (!sel) RETURN(RC_FAIL); + + sel->tag = tlv_tag; + + sel->want_nulls = (tlv_len == -1); + if (sel->prev && sel->prev->left != -1) + { + /* Check that the parent frame is big enough */ + if (sel->prev->left < + tlvl + (tlv_len == -1 ? 0 : tlv_len)) + RETURN(RC_FAIL); + if (tlv_len == -1) + sel->left = sel->prev->left - tlvl; + else + sel->left = tlv_len; + } + else + { + sel->left = tlv_len; + } + if (type_variant == ASN_OSUBV_ANY && + (tag_mode != 1 || sel->cont_level)) + APPEND(buf_ptr, tlvl); + sel->got += tlvl; + ADVANCE(tlvl); + + ASN_DEBUG("+EXPECT2 got=%ld left=%ld, wn=%d, clvl=%d", + (long)sel->got, (long)sel->left, + sel->want_nulls, sel->cont_level); + } + while (tlv_constr); + if (sel == NULL) + { + /* Finished operation, "phase out" */ + ASN_DEBUG("Phase out"); + _CH_PHASE(ctx, +3); + break; + } + + NEXT_PHASE(ctx); + /* Fall through */ + case 2: + stck = (struct _stack *)ctx->ptr; + sel = stck->cur_ptr; + ASN_DEBUG("Phase 2: Need %ld bytes, size=%ld, alrg=%ld, wn=%d", + (long)sel->left, (long)size, (long)sel->got, + sel->want_nulls); + { + ber_tlv_len_t len; + + assert(sel->left >= 0); + + len = ((ber_tlv_len_t)size < sel->left) + ? (ber_tlv_len_t)size + : sel->left; + if (len > 0) { - if (!size) RETURN(RC_WMORE); - if (type_variant == ASN_OSUBV_BIT && !ctx->context) + if (type_variant == ASN_OSUBV_BIT && + sel->bits_chopped == 0) { + /* Put the unused-bits-octet away */ st->bits_unused = *(const uint8_t *)buf_ptr; - ctx->left--; - ADVANCE(1); + APPEND(((const char *)buf_ptr + 1), + (len - 1)); + sel->bits_chopped = 1; } - APPEND(buf_ptr, size); - assert(ctx->context > 0); - ctx->left -= size; - ADVANCE(size); + else + { + APPEND(buf_ptr, len); + } + ADVANCE(len); + sel->left -= len; + sel->got += len; + } + + if (sel->left) + { + ASN_DEBUG("OS left %ld, size = %ld, wn=%d\n", + (long)sel->left, (long)size, + sel->want_nulls); RETURN(RC_WMORE); } - else - { - if (type_variant == ASN_OSUBV_BIT && !ctx->context && - ctx->left) - { - st->bits_unused = *(const uint8_t *)buf_ptr; - ctx->left--; - ADVANCE(1); - } - APPEND(buf_ptr, ctx->left); - ADVANCE(ctx->left); - ctx->left = 0; - NEXT_PHASE(ctx); - } - break; + PREV_PHASE(ctx); + goto phase1; + } + break; + case 3: + phase3: + /* + * Primitive form, no stack required. + */ + assert(ctx->left >= 0); + + if (size < (size_t)ctx->left) + { + if (!size) RETURN(RC_WMORE); + if (type_variant == ASN_OSUBV_BIT && !ctx->context) + { + st->bits_unused = *(const uint8_t *)buf_ptr; + ctx->left--; + ADVANCE(1); + } + APPEND(buf_ptr, size); + assert(ctx->context > 0); + ctx->left -= size; + ADVANCE(size); + RETURN(RC_WMORE); + } + else + { + if (type_variant == ASN_OSUBV_BIT && !ctx->context && + ctx->left) + { + st->bits_unused = *(const uint8_t *)buf_ptr; + ctx->left--; + ADVANCE(1); + } + APPEND(buf_ptr, ctx->left); + ADVANCE(ctx->left); + ctx->left = 0; + + NEXT_PHASE(ctx); + } + break; } if (sel) { ASN_DEBUG("3sel p=%p, wn=%d, l=%ld, g=%ld, size=%ld", sel->prev, - sel->want_nulls, (long)sel->left, (long)sel->got, - (long)size); + sel->want_nulls, (long)sel->left, (long)sel->got, + (long)size); if (sel->prev || sel->want_nulls > 1 || sel->left > 0) { RETURN(RC_WMORE); @@ -578,9 +578,9 @@ asn_dec_rval_t OCTET_STRING_decode_ber(asn_codec_ctx_t *opt_codec_ctx, } ASN_DEBUG("Took %ld bytes to encode %s: [%s]:%ld", (long)consumed_myself, - td->name, - (type_variant == ASN_OSUBV_STR) ? (char *)st->buf : "", - (long)st->size); + td->name, + (type_variant == ASN_OSUBV_STR) ? (char *)st->buf : "", + (long)st->size); RETURN(RC_OK); } @@ -589,9 +589,9 @@ asn_dec_rval_t OCTET_STRING_decode_ber(asn_codec_ctx_t *opt_codec_ctx, * Encode OCTET STRING type using DER. */ asn_enc_rval_t OCTET_STRING_encode_der(asn_TYPE_descriptor_t *td, void *sptr, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { asn_enc_rval_t er; asn_OCTET_STRING_specifics_t *specs = @@ -602,7 +602,7 @@ asn_enc_rval_t OCTET_STRING_encode_der(asn_TYPE_descriptor_t *td, void *sptr, int fix_last_byte = 0; ASN_DEBUG("%s %s as OCTET STRING", cb ? "Estimating" : "Encoding", - td->name); + td->name); /* * Write tags. @@ -660,10 +660,10 @@ cb_failed: } asn_enc_rval_t OCTET_STRING_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, - int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { static const char *h2c = "0123456789ABCDEF"; const OCTET_STRING_t *st = (const OCTET_STRING_t *)sptr; @@ -718,7 +718,7 @@ asn_enc_rval_t OCTET_STRING_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, } if (p - scratch) { - p--; /* Remove the tail space */ + p--; /* Remove the tail space */ _ASN_CALLBACK(scratch, p - scratch); /* Dump the rest */ er.encoded += p - scratch; if (st->size > 16) _i_ASN_TEXT_INDENT(1, ilevel - 1); @@ -824,8 +824,8 @@ static int OS__check_escaped_control_char(const void *buf, int size) } static int OCTET_STRING__handle_control_chars(void *struct_ptr, - const void *chunk_buf, - size_t chunk_size) + const void *chunk_buf, + size_t chunk_size) { /* * This might be one of the escape sequences @@ -850,10 +850,10 @@ static int OCTET_STRING__handle_control_chars(void *struct_ptr, } asn_enc_rval_t OCTET_STRING_encode_xer_utf8(asn_TYPE_descriptor_t *td, - void *sptr, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *sptr, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { const OCTET_STRING_t *st = (const OCTET_STRING_t *)sptr; asn_enc_rval_t er; @@ -883,7 +883,7 @@ asn_enc_rval_t OCTET_STRING_encode_xer_utf8(asn_TYPE_descriptor_t *td, { if (((buf - ss) && cb(ss, buf - ss, app_key) < 0) || cb(OCTET_STRING__xer_escape_table[ch].string, s_len, - app_key) < 0) + app_key) < 0) _ASN_ENCODE_FAILED; encoded_len += (buf - ss) + s_len; ss = buf + 1; @@ -901,9 +901,9 @@ asn_enc_rval_t OCTET_STRING_encode_xer_utf8(asn_TYPE_descriptor_t *td, * Convert from hexadecimal format (cstring): "AB CD EF" */ static ssize_t OCTET_STRING__convert_hexadecimal(void *sptr, - const void *chunk_buf, - size_t chunk_size, - int have_more) + const void *chunk_buf, + size_t chunk_size, + int have_more) { OCTET_STRING_t *st = (OCTET_STRING_t *)sptr; const char *chunk_stop = (const char *)chunk_buf; @@ -930,44 +930,44 @@ static ssize_t OCTET_STRING__convert_hexadecimal(void *sptr, int ch = *(const unsigned char *)p; switch (ch) { - case 0x09: - case 0x0a: - case 0x0c: - case 0x0d: - case 0x20: - /* Ignore whitespace */ - continue; - case 0x30: - case 0x31: - case 0x32: - case 0x33: - case 0x34: /*01234*/ - case 0x35: - case 0x36: - case 0x37: - case 0x38: - case 0x39: /*56789*/ - clv = (clv << 4) + (ch - 0x30); - break; - case 0x41: - case 0x42: - case 0x43: /* ABC */ - case 0x44: - case 0x45: - case 0x46: /* DEF */ - clv = (clv << 4) + (ch - 0x41 + 10); - break; - case 0x61: - case 0x62: - case 0x63: /* abc */ - case 0x64: - case 0x65: - case 0x66: /* def */ - clv = (clv << 4) + (ch - 0x61 + 10); - break; - default: - *buf = 0; /* JIC */ - return -1; + case 0x09: + case 0x0a: + case 0x0c: + case 0x0d: + case 0x20: + /* Ignore whitespace */ + continue; + case 0x30: + case 0x31: + case 0x32: + case 0x33: + case 0x34: /*01234*/ + case 0x35: + case 0x36: + case 0x37: + case 0x38: + case 0x39: /*56789*/ + clv = (clv << 4) + (ch - 0x30); + break; + case 0x41: + case 0x42: + case 0x43: /* ABC */ + case 0x44: + case 0x45: + case 0x46: /* DEF */ + clv = (clv << 4) + (ch - 0x41 + 10); + break; + case 0x61: + case 0x62: + case 0x63: /* abc */ + case 0x64: + case 0x65: + case 0x66: /* def */ + clv = (clv << 4) + (ch - 0x61 + 10); + break; + default: + *buf = 0; /* JIC */ + return -1; } if (half++) { @@ -1008,7 +1008,7 @@ static ssize_t OCTET_STRING__convert_hexadecimal(void *sptr, * Convert from binary format: "00101011101" */ static ssize_t OCTET_STRING__convert_binary(void *sptr, const void *chunk_buf, - size_t chunk_size, int have_more) + size_t chunk_size, int have_more) { BIT_STRING_t *st = (BIT_STRING_t *)sptr; const char *p = (const char *)chunk_buf; @@ -1038,25 +1038,25 @@ static ssize_t OCTET_STRING__convert_binary(void *sptr, const void *chunk_buf, int ch = *(const unsigned char *)p; switch (ch) { - case 0x09: - case 0x0a: - case 0x0c: - case 0x0d: - case 0x20: - /* Ignore whitespace */ - break; - case 0x30: - case 0x31: - if (bits_unused-- <= 0) - { - *++buf = 0; /* Clean the cell */ - bits_unused = 7; - } - *buf |= (ch & 1) << bits_unused; - break; - default: - st->bits_unused = bits_unused; - return -1; + case 0x09: + case 0x0a: + case 0x0c: + case 0x0d: + case 0x20: + /* Ignore whitespace */ + break; + case 0x30: + case 0x31: + if (bits_unused-- <= 0) + { + *++buf = 0; /* Clean the cell */ + bits_unused = 7; + } + *buf |= (ch & 1) << bits_unused; + break; + default: + st->bits_unused = bits_unused; + return -1; } } @@ -1081,7 +1081,7 @@ static ssize_t OCTET_STRING__convert_binary(void *sptr, const void *chunk_buf, * Something like strtod(), but with stricter rules. */ static int OS__strtoent(int base, const char *buf, const char *end, - int32_t *ret_value) + int32_t *ret_value) { int32_t val = 0; const char *p; @@ -1095,39 +1095,39 @@ static int OS__strtoent(int base, const char *buf, const char *end, switch (ch) { - case 0x30: - case 0x31: - case 0x32: - case 0x33: - case 0x34: /*01234*/ - case 0x35: - case 0x36: - case 0x37: - case 0x38: - case 0x39: /*56789*/ - val = val * base + (ch - 0x30); - break; - case 0x41: - case 0x42: - case 0x43: /* ABC */ - case 0x44: - case 0x45: - case 0x46: /* DEF */ - val = val * base + (ch - 0x41 + 10); - break; - case 0x61: - case 0x62: - case 0x63: /* abc */ - case 0x64: - case 0x65: - case 0x66: /* def */ - val = val * base + (ch - 0x61 + 10); - break; - case 0x3b: /* ';' */ - *ret_value = val; - return (p - buf) + 1; - default: - return -1; /* Character set error */ + case 0x30: + case 0x31: + case 0x32: + case 0x33: + case 0x34: /*01234*/ + case 0x35: + case 0x36: + case 0x37: + case 0x38: + case 0x39: /*56789*/ + val = val * base + (ch - 0x30); + break; + case 0x41: + case 0x42: + case 0x43: /* ABC */ + case 0x44: + case 0x45: + case 0x46: /* DEF */ + val = val * base + (ch - 0x41 + 10); + break; + case 0x61: + case 0x62: + case 0x63: /* abc */ + case 0x64: + case 0x65: + case 0x66: /* def */ + val = val * base + (ch - 0x61 + 10); + break; + case 0x3b: /* ';' */ + *ret_value = val; + return (p - buf) + 1; + default: + return -1; /* Character set error */ } } @@ -1139,7 +1139,7 @@ static int OS__strtoent(int base, const char *buf, const char *end, * Convert from the plain UTF-8 format, expanding entity references: "2 < 3" */ static ssize_t OCTET_STRING__convert_entrefs(void *sptr, const void *chunk_buf, - size_t chunk_size, int have_more) + size_t chunk_size, int have_more) { OCTET_STRING_t *st = (OCTET_STRING_t *)sptr; const char *p = (const char *)chunk_buf; @@ -1309,9 +1309,9 @@ static asn_dec_rval_t OCTET_STRING__decode_xer( asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td, void **sptr, const char *opt_mname, const void *buf_ptr, size_t size, int (*opt_unexpected_tag_decoder)(void *struct_ptr, const void *chunk_buf, - size_t chunk_size), + size_t chunk_size), ssize_t (*body_receiver)(void *struct_ptr, const void *chunk_buf, - size_t chunk_size, int have_more)) + size_t chunk_size, int have_more)) { OCTET_STRING_t *st = (OCTET_STRING_t *)*sptr; asn_OCTET_STRING_specifics_t *specs = @@ -1358,7 +1358,7 @@ static asn_dec_rval_t OCTET_STRING__decode_xer( ctx = (asn_struct_ctx_t *)(((char *)*sptr) + specs->ctx_offset); return xer_decode_general(opt_codec_ctx, ctx, *sptr, xml_tag, buf_ptr, size, - opt_unexpected_tag_decoder, body_receiver); + opt_unexpected_tag_decoder, body_receiver); stb_failed: FREEMEM(st); @@ -1372,49 +1372,49 @@ sta_failed: * Decode OCTET STRING from the hexadecimal data. */ asn_dec_rval_t OCTET_STRING_decode_xer_hex(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **sptr, const char *opt_mname, - const void *buf_ptr, size_t size) + asn_TYPE_descriptor_t *td, + void **sptr, const char *opt_mname, + const void *buf_ptr, size_t size) { return OCTET_STRING__decode_xer(opt_codec_ctx, td, sptr, opt_mname, buf_ptr, - size, 0, OCTET_STRING__convert_hexadecimal); + size, 0, OCTET_STRING__convert_hexadecimal); } /* * Decode OCTET STRING from the binary (0/1) data. */ asn_dec_rval_t OCTET_STRING_decode_xer_binary(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **sptr, - const char *opt_mname, - const void *buf_ptr, size_t size) + asn_TYPE_descriptor_t *td, + void **sptr, + const char *opt_mname, + const void *buf_ptr, size_t size) { return OCTET_STRING__decode_xer(opt_codec_ctx, td, sptr, opt_mname, buf_ptr, - size, 0, OCTET_STRING__convert_binary); + size, 0, OCTET_STRING__convert_binary); } /* * Decode OCTET STRING from the string (ASCII/UTF-8) data. */ asn_dec_rval_t OCTET_STRING_decode_xer_utf8(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **sptr, const char *opt_mname, - const void *buf_ptr, size_t size) + asn_TYPE_descriptor_t *td, + void **sptr, const char *opt_mname, + const void *buf_ptr, size_t size) { return OCTET_STRING__decode_xer(opt_codec_ctx, td, sptr, opt_mname, buf_ptr, - size, OCTET_STRING__handle_control_chars, - OCTET_STRING__convert_entrefs); + size, OCTET_STRING__handle_control_chars, + OCTET_STRING__convert_entrefs); } static int OCTET_STRING_per_get_characters(asn_per_data_t *po, uint8_t *buf, - size_t units, unsigned int bpc, - unsigned int unit_bits, long lb, - long ub, asn_per_constraints_t *pc) + size_t units, unsigned int bpc, + unsigned int unit_bits, long lb, + long ub, asn_per_constraints_t *pc) { uint8_t *end = buf + units * bpc; ASN_DEBUG("Expanding %d characters into (%ld..%ld):%d", (int)units, lb, ub, - unit_bits); + unit_bits); /* X.691: 27.5.4 */ if ((unsigned long)ub <= ((unsigned long)2 << (unit_bits - 1))) @@ -1444,19 +1444,19 @@ static int OCTET_STRING_per_get_characters(asn_per_data_t *po, uint8_t *buf, } switch (bpc) { - case 1: - *buf = value; - break; - case 2: - buf[0] = value >> 8; - buf[1] = value; - break; - case 4: - buf[0] = value >> 24; - buf[1] = value >> 16; - buf[2] = value >> 8; - buf[3] = value; - break; + case 1: + *buf = value; + break; + case 2: + buf[0] = value >> 8; + buf[1] = value; + break; + case 4: + buf[0] = value >> 24; + buf[1] = value >> 16; + buf[2] = value >> 8; + buf[3] = value; + break; } } return 0; @@ -1480,19 +1480,19 @@ static int OCTET_STRING_per_get_characters(asn_per_data_t *po, uint8_t *buf, } switch (bpc) { - case 1: - *buf = ch; - break; - case 2: - buf[0] = ch >> 8; - buf[1] = ch; - break; - case 4: - buf[0] = ch >> 24; - buf[1] = ch >> 16; - buf[2] = ch >> 8; - buf[3] = ch; - break; + case 1: + *buf = ch; + break; + case 2: + buf[0] = ch >> 8; + buf[1] = ch; + break; + case 4: + buf[0] = ch >> 24; + buf[1] = ch >> 16; + buf[2] = ch >> 8; + buf[3] = ch; + break; } } @@ -1500,15 +1500,15 @@ static int OCTET_STRING_per_get_characters(asn_per_data_t *po, uint8_t *buf, } static int OCTET_STRING_per_put_characters(asn_per_outp_t *po, - const uint8_t *buf, size_t units, - unsigned int bpc, - unsigned int unit_bits, long lb, - long ub, asn_per_constraints_t *pc) + const uint8_t *buf, size_t units, + unsigned int bpc, + unsigned int unit_bits, long lb, + long ub, asn_per_constraints_t *pc) { const uint8_t *end = buf + units * bpc; ASN_DEBUG("Squeezing %d characters into (%ld..%ld):%d (%d bpc)", (int)units, - lb, ub, unit_bits, bpc); + lb, ub, unit_bits, bpc); /* X.691: 27.5.4 */ if ((unsigned long)ub <= ((unsigned long)2 << (unit_bits - 1))) @@ -1524,18 +1524,18 @@ static int OCTET_STRING_per_put_characters(asn_per_outp_t *po, uint32_t value; switch (bpc) { - case 1: - value = *buf; - break; - case 2: - value = (buf[0] << 8) | buf[1]; - break; - case 4: - value = (buf[0] << 24) | (buf[1] << 16) | - (buf[2] << 8) | buf[3]; - break; - default: - return -1; + case 1: + value = *buf; + break; + case 2: + value = (buf[0] << 8) | buf[1]; + break; + case 4: + value = (buf[0] << 24) | (buf[1] << 16) | + (buf[2] << 8) | buf[3]; + break; + default: + return -1; } code = pc->value2code(value); if (code < 0) @@ -1562,18 +1562,18 @@ static int OCTET_STRING_per_put_characters(asn_per_outp_t *po, uint32_t value; switch (bpc) { - case 1: - value = *buf; - break; - case 2: - value = (buf[0] << 8) | buf[1]; - break; - case 4: - value = (buf[0] << 24) | (buf[1] << 16) | - (buf[2] << 8) | buf[3]; - break; - default: - return -1; + case 1: + value = *buf; + break; + case 2: + value = (buf[0] << 8) | buf[1]; + break; + case 4: + value = (buf[0] << 24) | (buf[1] << 16) | + (buf[2] << 8) | buf[3]; + break; + default: + return -1; } ch = value - lb; if (ch < 0 || ch > ub) @@ -1591,9 +1591,9 @@ static int OCTET_STRING_per_put_characters(asn_per_outp_t *po, } asn_dec_rval_t OCTET_STRING_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd) { asn_OCTET_STRING_specifics_t *specs = td->specifics ? (asn_OCTET_STRING_specifics_t *)td->specifics @@ -1630,29 +1630,29 @@ asn_dec_rval_t OCTET_STRING_decode_uper(asn_codec_ctx_t *opt_codec_ctx, switch (specs->subvariant) { - default: - case ASN_OSUBV_ANY: - ASN_DEBUG("Unrecognized subvariant %d", specs->subvariant); - RETURN(RC_FAIL); - case ASN_OSUBV_BIT: - canonical_unit_bits = unit_bits = 1; - bpc = OS__BPC_BIT; - break; - case ASN_OSUBV_STR: - canonical_unit_bits = unit_bits = 8; - if (cval->flags & APC_CONSTRAINED) unit_bits = cval->range_bits; - bpc = OS__BPC_CHAR; - break; - case ASN_OSUBV_U16: - canonical_unit_bits = unit_bits = 16; - if (cval->flags & APC_CONSTRAINED) unit_bits = cval->range_bits; - bpc = OS__BPC_U16; - break; - case ASN_OSUBV_U32: - canonical_unit_bits = unit_bits = 32; - if (cval->flags & APC_CONSTRAINED) unit_bits = cval->range_bits; - bpc = OS__BPC_U32; - break; + default: + case ASN_OSUBV_ANY: + ASN_DEBUG("Unrecognized subvariant %d", specs->subvariant); + RETURN(RC_FAIL); + case ASN_OSUBV_BIT: + canonical_unit_bits = unit_bits = 1; + bpc = OS__BPC_BIT; + break; + case ASN_OSUBV_STR: + canonical_unit_bits = unit_bits = 8; + if (cval->flags & APC_CONSTRAINED) unit_bits = cval->range_bits; + bpc = OS__BPC_CHAR; + break; + case ASN_OSUBV_U16: + canonical_unit_bits = unit_bits = 16; + if (cval->flags & APC_CONSTRAINED) unit_bits = cval->range_bits; + bpc = OS__BPC_U16; + break; + case ASN_OSUBV_U32: + canonical_unit_bits = unit_bits = 32; + if (cval->flags & APC_CONSTRAINED) unit_bits = cval->range_bits; + bpc = OS__BPC_U32; + break; } /* @@ -1665,8 +1665,8 @@ asn_dec_rval_t OCTET_STRING_decode_uper(asn_codec_ctx_t *opt_codec_ctx, } ASN_DEBUG("PER Decoding %s size %ld .. %ld bits %d", - csiz->flags & APC_EXTENSIBLE ? "extensible" : "non-extensible", - csiz->lower_bound, csiz->upper_bound, csiz->effective_bits); + csiz->flags & APC_EXTENSIBLE ? "extensible" : "non-extensible", + csiz->lower_bound, csiz->upper_bound, csiz->effective_bits); if (csiz->flags & APC_EXTENSIBLE) { @@ -1708,7 +1708,7 @@ asn_dec_rval_t OCTET_STRING_decode_uper(asn_codec_ctx_t *opt_codec_ctx, if (bpc) { ASN_DEBUG("Encoding OCTET STRING size %ld", - csiz->upper_bound); + csiz->upper_bound); ret = OCTET_STRING_per_get_characters( pd, st->buf, csiz->upper_bound, bpc, unit_bits, cval->lower_bound, cval->upper_bound, pc); @@ -1717,9 +1717,9 @@ asn_dec_rval_t OCTET_STRING_decode_uper(asn_codec_ctx_t *opt_codec_ctx, else { ASN_DEBUG("Encoding BIT STRING size %ld", - csiz->upper_bound); + csiz->upper_bound); ret = per_get_many_bits(pd, st->buf, 0, - unit_bits * csiz->upper_bound); + unit_bits * csiz->upper_bound); } if (ret < 0) RETURN(RC_WMORE); consumed_myself += unit_bits * csiz->upper_bound; @@ -1747,8 +1747,8 @@ asn_dec_rval_t OCTET_STRING_decode_uper(asn_codec_ctx_t *opt_codec_ctx, raw_len += csiz->lower_bound; ASN_DEBUG("Got PER length eb %ld, len %ld, %s (%s)", - (long)csiz->effective_bits, (long)raw_len, - repeat ? "repeat" : "once", td->name); + (long)csiz->effective_bits, (long)raw_len, + repeat ? "repeat" : "once", td->name); if (bpc) { len_bytes = raw_len * bpc; @@ -1787,8 +1787,8 @@ asn_dec_rval_t OCTET_STRING_decode_uper(asn_codec_ctx_t *opt_codec_ctx, } asn_enc_rval_t OCTET_STRING_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *sptr, asn_per_outp_t *po) + asn_per_constraints_t *constraints, + void *sptr, asn_per_outp_t *po) { asn_OCTET_STRING_specifics_t *specs = td->specifics ? (asn_OCTET_STRING_specifics_t *)td->specifics @@ -1829,34 +1829,34 @@ asn_enc_rval_t OCTET_STRING_encode_uper(asn_TYPE_descriptor_t *td, switch (specs->subvariant) { - default: - case ASN_OSUBV_ANY: - _ASN_ENCODE_FAILED; - case ASN_OSUBV_BIT: - canonical_unit_bits = unit_bits = 1; - bpc = OS__BPC_BIT; - sizeinunits = st->size * 8 - (st->bits_unused & 0x07); - ASN_DEBUG("BIT STRING of %d bytes, %d bits unused", sizeinunits, - st->bits_unused); - break; - case ASN_OSUBV_STR: - canonical_unit_bits = unit_bits = 8; - if (cval->flags & APC_CONSTRAINED) unit_bits = cval->range_bits; - bpc = OS__BPC_CHAR; - sizeinunits = st->size; - break; - case ASN_OSUBV_U16: - canonical_unit_bits = unit_bits = 16; - if (cval->flags & APC_CONSTRAINED) unit_bits = cval->range_bits; - bpc = OS__BPC_U16; - sizeinunits = st->size / 2; - break; - case ASN_OSUBV_U32: - canonical_unit_bits = unit_bits = 32; - if (cval->flags & APC_CONSTRAINED) unit_bits = cval->range_bits; - bpc = OS__BPC_U32; - sizeinunits = st->size / 4; - break; + default: + case ASN_OSUBV_ANY: + _ASN_ENCODE_FAILED; + case ASN_OSUBV_BIT: + canonical_unit_bits = unit_bits = 1; + bpc = OS__BPC_BIT; + sizeinunits = st->size * 8 - (st->bits_unused & 0x07); + ASN_DEBUG("BIT STRING of %d bytes, %d bits unused", sizeinunits, + st->bits_unused); + break; + case ASN_OSUBV_STR: + canonical_unit_bits = unit_bits = 8; + if (cval->flags & APC_CONSTRAINED) unit_bits = cval->range_bits; + bpc = OS__BPC_CHAR; + sizeinunits = st->size; + break; + case ASN_OSUBV_U16: + canonical_unit_bits = unit_bits = 16; + if (cval->flags & APC_CONSTRAINED) unit_bits = cval->range_bits; + bpc = OS__BPC_U16; + sizeinunits = st->size / 2; + break; + case ASN_OSUBV_U32: + canonical_unit_bits = unit_bits = 32; + if (cval->flags & APC_CONSTRAINED) unit_bits = cval->range_bits; + bpc = OS__BPC_U32; + sizeinunits = st->size / 4; + break; } ASN_DEBUG( @@ -1900,9 +1900,9 @@ asn_enc_rval_t OCTET_STRING_encode_uper(asn_TYPE_descriptor_t *td, if (csiz->effective_bits >= 0) { ASN_DEBUG("Encoding %d bytes (%ld), length in %d bits", st->size, - sizeinunits - csiz->lower_bound, csiz->effective_bits); + sizeinunits - csiz->lower_bound, csiz->effective_bits); ret = per_put_few_bits(po, sizeinunits - csiz->lower_bound, - csiz->effective_bits); + csiz->effective_bits); if (ret) _ASN_ENCODE_FAILED; if (bpc) { @@ -1959,7 +1959,7 @@ asn_enc_rval_t OCTET_STRING_encode_uper(asn_TYPE_descriptor_t *td, } int OCTET_STRING_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { static const char *h2c = "0123456789ABCDEF"; const OCTET_STRING_t *st = (const OCTET_STRING_t *)sptr; @@ -2002,8 +2002,8 @@ int OCTET_STRING_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, } int OCTET_STRING_print_utf8(asn_TYPE_descriptor_t *td, const void *sptr, - int ilevel, asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, + void *app_key) { const OCTET_STRING_t *st = (const OCTET_STRING_t *)sptr; @@ -2102,7 +2102,7 @@ int OCTET_STRING_fromBuf(OCTET_STRING_t *st, const char *str, int len) } OCTET_STRING_t *OCTET_STRING_new_fromBuf(asn_TYPE_descriptor_t *td, - const char *str, int len) + const char *str, int len) { asn_OCTET_STRING_specifics_t *specs = td->specifics ? (asn_OCTET_STRING_specifics_t *)td->specifics diff --git a/src/core/libs/supl/asn-supl/OCTET_STRING.h b/src/core/libs/supl/asn-supl/OCTET_STRING.h index 3aa1ba86b..ed19795af 100644 --- a/src/core/libs/supl/asn-supl/OCTET_STRING.h +++ b/src/core/libs/supl/asn-supl/OCTET_STRING.h @@ -59,7 +59,7 @@ extern "C" * allocate empty OCTET STRING. */ OCTET_STRING_t *OCTET_STRING_new_fromBuf(asn_TYPE_descriptor_t *td, - const char *str, int len); + const char *str, int len); /**************************** * Internally useful stuff. * diff --git a/src/core/libs/supl/asn-supl/Pathloss.c b/src/core/libs/supl/asn-supl/Pathloss.c index 5fd48e72a..33c93f128 100644 --- a/src/core/libs/supl/asn-supl/Pathloss.c +++ b/src/core/libs/supl/asn-supl/Pathloss.c @@ -7,14 +7,14 @@ #include "Pathloss.h" int Pathloss_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int Pathloss_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -55,68 +55,68 @@ static void Pathloss_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void Pathloss_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { Pathloss_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int Pathloss_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { Pathloss_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t Pathloss_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, + int tag_mode) { Pathloss_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t Pathloss_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { Pathloss_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t Pathloss_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { Pathloss_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t Pathloss_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { Pathloss_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t Pathloss_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { Pathloss_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t Pathloss_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { Pathloss_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-supl/PosMethod.c b/src/core/libs/supl/asn-supl/PosMethod.c index 7dd104756..5a5937d08 100644 --- a/src/core/libs/supl/asn-supl/PosMethod.c +++ b/src/core/libs/supl/asn-supl/PosMethod.c @@ -7,7 +7,7 @@ #include "PosMethod.h" int PosMethod_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { /* Replace with underlying type checker */ td->check_constraints = asn_DEF_ENUMERATED.check_constraints; @@ -38,68 +38,68 @@ static void PosMethod_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void PosMethod_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { PosMethod_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int PosMethod_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { PosMethod_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t PosMethod_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, + int tag_mode) { PosMethod_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t PosMethod_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { PosMethod_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t PosMethod_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { PosMethod_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t PosMethod_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { PosMethod_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t PosMethod_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { PosMethod_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t PosMethod_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { PosMethod_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-supl/PosPayLoad.c b/src/core/libs/supl/asn-supl/PosPayLoad.c index cf9a2c57d..30e1926c1 100644 --- a/src/core/libs/supl/asn-supl/PosPayLoad.c +++ b/src/core/libs/supl/asn-supl/PosPayLoad.c @@ -16,7 +16,7 @@ static int memb_tia801payload_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,15 +30,15 @@ static int memb_tia801payload_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_rrcPayload_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const OCTET_STRING_t *st = (const OCTET_STRING_t *)sptr; size_t size; @@ -46,7 +46,7 @@ static int memb_rrcPayload_constraint_1(asn_TYPE_descriptor_t *td, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -60,15 +60,15 @@ static int memb_rrcPayload_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_rrlpPayload_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const OCTET_STRING_t *st = (const OCTET_STRING_t *)sptr; size_t size; @@ -76,7 +76,7 @@ static int memb_rrlpPayload_constraint_1(asn_TYPE_descriptor_t *td, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -90,7 +90,7 @@ static int memb_rrlpPayload_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -121,17 +121,17 @@ static asn_per_constraints_t ASN_PER_TYPE_POS_PAY_LOAD_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_PosPayLoad_1[] = { {ATF_NOFLAGS, 0, offsetof(struct PosPayLoad, choice.tia801payload), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_OCTET_STRING, memb_tia801payload_constraint_1, - &ASN_PER_MEMB_TIA801PAYLOAD_CONSTR_2, 0, "tia801payload"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_OCTET_STRING, memb_tia801payload_constraint_1, + &ASN_PER_MEMB_TIA801PAYLOAD_CONSTR_2, 0, "tia801payload"}, {ATF_NOFLAGS, 0, offsetof(struct PosPayLoad, choice.rrcPayload), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_OCTET_STRING, memb_rrcPayload_constraint_1, - &ASN_PER_MEMB_RRC_PAYLOAD_CONSTR_3, 0, "rrcPayload"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_OCTET_STRING, memb_rrcPayload_constraint_1, + &ASN_PER_MEMB_RRC_PAYLOAD_CONSTR_3, 0, "rrcPayload"}, {ATF_NOFLAGS, 0, offsetof(struct PosPayLoad, choice.rrlpPayload), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_OCTET_STRING, memb_rrlpPayload_constraint_1, - &ASN_PER_MEMB_RRLP_PAYLOAD_CONSTR_4, 0, "rrlpPayload"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_OCTET_STRING, memb_rrlpPayload_constraint_1, + &ASN_PER_MEMB_RRLP_PAYLOAD_CONSTR_4, 0, "rrlpPayload"}, }; static asn_TYPE_tag2member_t asn_MAP_PosPayLoad_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* tia801payload at 15 */ diff --git a/src/core/libs/supl/asn-supl/PosProtocol.c b/src/core/libs/supl/asn-supl/PosProtocol.c index 2e157aae0..38181f179 100644 --- a/src/core/libs/supl/asn-supl/PosProtocol.c +++ b/src/core/libs/supl/asn-supl/PosProtocol.c @@ -8,20 +8,20 @@ static asn_TYPE_member_t asn_MBR_PosProtocol_1[] = { {ATF_NOFLAGS, 0, offsetof(struct PosProtocol, tia801), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "tia801"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "tia801"}, {ATF_NOFLAGS, 0, offsetof(struct PosProtocol, rrlp), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "rrlp"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "rrlp"}, {ATF_NOFLAGS, 0, offsetof(struct PosProtocol, rrc), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "rrc"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "rrc"}, }; static ber_tlv_tag_t asn_DEF_PosProtocol_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-supl/PosTechnology.c b/src/core/libs/supl/asn-supl/PosTechnology.c index 8ed7b2f7c..5fd76ed6d 100644 --- a/src/core/libs/supl/asn-supl/PosTechnology.c +++ b/src/core/libs/supl/asn-supl/PosTechnology.c @@ -8,40 +8,40 @@ static asn_TYPE_member_t asn_MBR_PosTechnology_1[] = { {ATF_NOFLAGS, 0, offsetof(struct PosTechnology, agpsSETassisted), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "agpsSETassisted"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "agpsSETassisted"}, {ATF_NOFLAGS, 0, offsetof(struct PosTechnology, agpsSETBased), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "agpsSETBased"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "agpsSETBased"}, {ATF_NOFLAGS, 0, offsetof(struct PosTechnology, autonomousGPS), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "autonomousGPS"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "autonomousGPS"}, {ATF_NOFLAGS, 0, offsetof(struct PosTechnology, aFLT), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "aFLT"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "aFLT"}, {ATF_NOFLAGS, 0, offsetof(struct PosTechnology, eCID), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "eCID"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "eCID"}, {ATF_NOFLAGS, 0, offsetof(struct PosTechnology, eOTD), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "eOTD"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "eOTD"}, {ATF_NOFLAGS, 0, offsetof(struct PosTechnology, oTDOA), - (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "oTDOA"}, + (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "oTDOA"}, }; static ber_tlv_tag_t asn_DEF_PosTechnology_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -84,7 +84,7 @@ asn_TYPE_descriptor_t asn_DEF_PosTechnology = { asn_DEF_PosTechnology_tags_1, /* Same as above */ sizeof(asn_DEF_PosTechnology_tags_1) / sizeof(asn_DEF_PosTechnology_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_PosTechnology_1, 7, /* Elements count */ &asn_SPC_PosTechnology_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-supl/Position.c b/src/core/libs/supl/asn-supl/Position.c index 87d66fec4..6f0cbc822 100644 --- a/src/core/libs/supl/asn-supl/Position.c +++ b/src/core/libs/supl/asn-supl/Position.c @@ -8,21 +8,21 @@ static asn_TYPE_member_t asn_MBR_Position_1[] = { {ATF_NOFLAGS, 0, offsetof(struct Position, timestamp), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_UTCTime, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "timestamp"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_UTCTime, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "timestamp"}, {ATF_NOFLAGS, 0, offsetof(struct Position, positionEstimate), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_PositionEstimate, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "positionEstimate"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_PositionEstimate, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "positionEstimate"}, {ATF_POINTER, 1, offsetof(struct Position, velocity), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), +1, /* EXPLICIT tag at current level */ - &asn_DEF_Velocity, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "velocity"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), +1, /* EXPLICIT tag at current level */ + &asn_DEF_Velocity, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "velocity"}, }; static int asn_MAP_Position_oms_1[] = {2}; static ber_tlv_tag_t asn_DEF_Position_tags_1[] = { diff --git a/src/core/libs/supl/asn-supl/Position.h b/src/core/libs/supl/asn-supl/Position.h index 0ec959c08..ca5581fc3 100644 --- a/src/core/libs/supl/asn-supl/Position.h +++ b/src/core/libs/supl/asn-supl/Position.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include #include "PositionEstimate.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-supl/PositionEstimate.c b/src/core/libs/supl/asn-supl/PositionEstimate.c index c4481cd56..828bc4f04 100644 --- a/src/core/libs/supl/asn-supl/PositionEstimate.c +++ b/src/core/libs/supl/asn-supl/PositionEstimate.c @@ -7,9 +7,9 @@ #include "PositionEstimate.h" static int latitudeSign_2_constraint(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { /* Replace with underlying type checker */ td->check_constraints = asn_DEF_ENUMERATED.check_constraints; @@ -40,57 +40,57 @@ static void latitudeSign_2_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } static void latitudeSign_2_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { latitudeSign_2_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } static int latitudeSign_2_print(asn_TYPE_descriptor_t *td, - const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + const void *struct_ptr, int ilevel, + asn_app_consume_bytes_f *cb, void *app_key) { latitudeSign_2_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } static asn_dec_rval_t latitudeSign_2_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, + const void *bufptr, size_t size, + int tag_mode) { latitudeSign_2_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } static asn_enc_rval_t latitudeSign_2_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { latitudeSign_2_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } static asn_dec_rval_t latitudeSign_2_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { latitudeSign_2_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } static asn_enc_rval_t latitudeSign_2_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { latitudeSign_2_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); @@ -103,7 +103,7 @@ static asn_dec_rval_t latitudeSign_2_decode_uper( { latitudeSign_2_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } static asn_enc_rval_t latitudeSign_2_encode_uper( @@ -123,7 +123,7 @@ static int memb_uncertaintySemiMajor_constraint_7( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -137,7 +137,7 @@ static int memb_uncertaintySemiMajor_constraint_7( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -151,7 +151,7 @@ static int memb_uncertaintySemiMinor_constraint_7( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -165,7 +165,7 @@ static int memb_uncertaintySemiMinor_constraint_7( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -179,7 +179,7 @@ static int memb_orientationMajorAxis_constraint_7( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -193,22 +193,22 @@ static int memb_orientationMajorAxis_constraint_7( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_latitude_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -222,22 +222,22 @@ static int memb_latitude_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_longitude_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -251,22 +251,22 @@ static int memb_longitude_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_confidence_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -280,7 +280,7 @@ static int memb_confidence_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -372,27 +372,27 @@ static /* Use -fall-defs-global to expose */ static asn_TYPE_member_t asn_MBR_uncertainty_7[] = { {ATF_NOFLAGS, 0, offsetof(struct uncertainty, uncertaintySemiMajor), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_uncertaintySemiMajor_constraint_7, - &ASN_PER_MEMB_UNCERTAINTY_SEMI_MAJOR_CONSTR_8, 0, "uncertaintySemiMajor"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_uncertaintySemiMajor_constraint_7, + &ASN_PER_MEMB_UNCERTAINTY_SEMI_MAJOR_CONSTR_8, 0, "uncertaintySemiMajor"}, {ATF_NOFLAGS, 0, offsetof(struct uncertainty, uncertaintySemiMinor), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_uncertaintySemiMinor_constraint_7, - &ASN_PER_MEMB_UNCERTAINTY_SEMI_MINOR_CONSTR_9, 0, "uncertaintySemiMinor"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_uncertaintySemiMinor_constraint_7, + &ASN_PER_MEMB_UNCERTAINTY_SEMI_MINOR_CONSTR_9, 0, "uncertaintySemiMinor"}, {ATF_NOFLAGS, 0, offsetof(struct uncertainty, orientationMajorAxis), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_orientationMajorAxis_constraint_7, - &ASN_PER_MEMB_ORIENTATION_MAJOR_AXIS_CONSTR_10, 0, "orientationMajorAxis"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_orientationMajorAxis_constraint_7, + &ASN_PER_MEMB_ORIENTATION_MAJOR_AXIS_CONSTR_10, 0, "orientationMajorAxis"}, }; static ber_tlv_tag_t asn_DEF_uncertainty_tags_7[] = { (ASN_TAG_CLASS_CONTEXT | (3 << 2)), (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_uncertainty_tag2el_7[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0}, /* uncertaintySemiMajor at 77 */ + 0}, /* uncertaintySemiMajor at 77 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0}, /* uncertaintySemiMinor at 78 */ + 0}, /* uncertaintySemiMinor at 78 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, - 0} /* orientationMajorAxis at 79 */ + 0} /* orientationMajorAxis at 79 */ }; static asn_SEQUENCE_specifics_t asn_SPC_uncertainty_specs_7 = { sizeof(struct uncertainty), @@ -426,7 +426,7 @@ static /* Use -fall-defs-global to expose */ asn_DEF_uncertainty_tags_7, /* Same as above */ sizeof(asn_DEF_uncertainty_tags_7) / sizeof(asn_DEF_uncertainty_tags_7[0]), /* 2 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_uncertainty_7, 3, /* Elements count */ &asn_SPC_uncertainty_specs_7 /* Additional specs */ @@ -434,34 +434,34 @@ static /* Use -fall-defs-global to expose */ static asn_TYPE_member_t asn_MBR_PositionEstimate_1[] = { {ATF_NOFLAGS, 0, offsetof(struct PositionEstimate, latitudeSign), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_latitudeSign_2, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "latitudeSign"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_latitudeSign_2, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "latitudeSign"}, {ATF_NOFLAGS, 0, offsetof(struct PositionEstimate, latitude), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_latitude_constraint_1, - &ASN_PER_MEMB_LATITUDE_CONSTR_5, 0, "latitude"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_latitude_constraint_1, + &ASN_PER_MEMB_LATITUDE_CONSTR_5, 0, "latitude"}, {ATF_NOFLAGS, 0, offsetof(struct PositionEstimate, longitude), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_longitude_constraint_1, - &ASN_PER_MEMB_LONGITUDE_CONSTR_6, 0, "longitude"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_longitude_constraint_1, + &ASN_PER_MEMB_LONGITUDE_CONSTR_6, 0, "longitude"}, {ATF_POINTER, 3, offsetof(struct PositionEstimate, uncertainty), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), 0, &asn_DEF_uncertainty_7, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "uncertainty"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), 0, &asn_DEF_uncertainty_7, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "uncertainty"}, {ATF_POINTER, 2, offsetof(struct PositionEstimate, confidence), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_confidence_constraint_1, - &ASN_PER_MEMB_CONFIDENCE_CONSTR_11, 0, "confidence"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_confidence_constraint_1, + &ASN_PER_MEMB_CONFIDENCE_CONSTR_11, 0, "confidence"}, {ATF_POINTER, 1, offsetof(struct PositionEstimate, altitudeInfo), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_AltitudeInfo, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "altitudeInfo"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_AltitudeInfo, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "altitudeInfo"}, }; static int asn_MAP_PositionEstimate_oms_1[] = {3, 4, 5}; static ber_tlv_tag_t asn_DEF_PositionEstimate_tags_1[] = { @@ -504,7 +504,7 @@ asn_TYPE_descriptor_t asn_DEF_PositionEstimate = { asn_DEF_PositionEstimate_tags_1, /* Same as above */ sizeof(asn_DEF_PositionEstimate_tags_1) / sizeof(asn_DEF_PositionEstimate_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_PositionEstimate_1, 6, /* Elements count */ &asn_SPC_PositionEstimate_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-supl/PrefMethod.c b/src/core/libs/supl/asn-supl/PrefMethod.c index aab9c63a1..41f0b5d0b 100644 --- a/src/core/libs/supl/asn-supl/PrefMethod.c +++ b/src/core/libs/supl/asn-supl/PrefMethod.c @@ -7,7 +7,7 @@ #include "PrefMethod.h" int PrefMethod_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { /* Replace with underlying type checker */ td->check_constraints = asn_DEF_ENUMERATED.check_constraints; @@ -38,69 +38,69 @@ static void PrefMethod_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void PrefMethod_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { PrefMethod_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int PrefMethod_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { PrefMethod_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t PrefMethod_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { PrefMethod_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t PrefMethod_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { PrefMethod_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t PrefMethod_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, const char *opt_mname, + const void *bufptr, size_t size) { PrefMethod_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t PrefMethod_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { PrefMethod_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t PrefMethod_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { PrefMethod_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t PrefMethod_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { PrefMethod_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-supl/PrimaryCCPCH-RSCP.c b/src/core/libs/supl/asn-supl/PrimaryCCPCH-RSCP.c index 6848d22fc..7e8f19505 100644 --- a/src/core/libs/supl/asn-supl/PrimaryCCPCH-RSCP.c +++ b/src/core/libs/supl/asn-supl/PrimaryCCPCH-RSCP.c @@ -7,15 +7,15 @@ #include "PrimaryCCPCH-RSCP.h" int PrimaryCCPCH_RSCP_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ int PrimaryCCPCH_RSCP_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -57,77 +57,77 @@ static void PrimaryCCPCH_RSCP_1_inherit_TYPE_descriptor( } void PrimaryCCPCH_RSCP_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { PrimaryCCPCH_RSCP_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int PrimaryCCPCH_RSCP_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, + void *app_key) { PrimaryCCPCH_RSCP_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t PrimaryCCPCH_RSCP_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const void *bufptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, + const void *bufptr, size_t size, + int tag_mode) { PrimaryCCPCH_RSCP_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t PrimaryCCPCH_RSCP_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { PrimaryCCPCH_RSCP_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t PrimaryCCPCH_RSCP_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { PrimaryCCPCH_RSCP_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t PrimaryCCPCH_RSCP_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { PrimaryCCPCH_RSCP_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t PrimaryCCPCH_RSCP_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { PrimaryCCPCH_RSCP_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t PrimaryCCPCH_RSCP_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { PrimaryCCPCH_RSCP_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-supl/PrimaryCPICH-Info.c b/src/core/libs/supl/asn-supl/PrimaryCPICH-Info.c index 64cfef469..02759cf87 100644 --- a/src/core/libs/supl/asn-supl/PrimaryCPICH-Info.c +++ b/src/core/libs/supl/asn-supl/PrimaryCPICH-Info.c @@ -15,7 +15,7 @@ static int memb_primaryScramblingCode_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ static int memb_primaryScramblingCode_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -42,16 +42,16 @@ static asn_per_constraints_t ASN_PER_MEMB_PRIMARY_SCRAMBLING_CODE_CONSTR_2 = { }; static asn_TYPE_member_t asn_MBR_PrimaryCPICH_Info_1[] = { {ATF_NOFLAGS, 0, offsetof(struct PrimaryCPICH_Info, primaryScramblingCode), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_primaryScramblingCode_constraint_1, - &ASN_PER_MEMB_PRIMARY_SCRAMBLING_CODE_CONSTR_2, 0, - "primaryScramblingCode"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_primaryScramblingCode_constraint_1, + &ASN_PER_MEMB_PRIMARY_SCRAMBLING_CODE_CONSTR_2, 0, + "primaryScramblingCode"}, }; static ber_tlv_tag_t asn_DEF_PrimaryCPICH_Info_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; static asn_TYPE_tag2member_t asn_MAP_PrimaryCPICH_Info_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, - 0} /* primaryScramblingCode at 186 */ + 0} /* primaryScramblingCode at 186 */ }; static asn_SEQUENCE_specifics_t asn_SPC_PrimaryCPICH_Info_specs_1 = { sizeof(struct PrimaryCPICH_Info), @@ -83,7 +83,7 @@ asn_TYPE_descriptor_t asn_DEF_PrimaryCPICH_Info = { asn_DEF_PrimaryCPICH_Info_tags_1, /* Same as above */ sizeof(asn_DEF_PrimaryCPICH_Info_tags_1) / sizeof(asn_DEF_PrimaryCPICH_Info_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_PrimaryCPICH_Info_1, 1, /* Elements count */ &asn_SPC_PrimaryCPICH_Info_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-supl/QoP.c b/src/core/libs/supl/asn-supl/QoP.c index efc9a9dcf..49f51f49a 100644 --- a/src/core/libs/supl/asn-supl/QoP.c +++ b/src/core/libs/supl/asn-supl/QoP.c @@ -7,15 +7,15 @@ #include "QoP.h" static int memb_horacc_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,21 +29,21 @@ static int memb_horacc_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_veracc_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -57,22 +57,22 @@ static int memb_veracc_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_maxLocAge_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -86,21 +86,21 @@ static int memb_maxLocAge_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_delay_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -114,7 +114,7 @@ static int memb_delay_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -145,21 +145,21 @@ static asn_per_constraints_t ASN_PER_MEMB_DELAY_CONSTR_5 = { }; static asn_TYPE_member_t asn_MBR_QoP_1[] = { {ATF_NOFLAGS, 0, offsetof(struct QoP, horacc), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_horacc_constraint_1, - &ASN_PER_MEMB_HORACC_CONSTR_2, 0, "horacc"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_horacc_constraint_1, + &ASN_PER_MEMB_HORACC_CONSTR_2, 0, "horacc"}, {ATF_POINTER, 3, offsetof(struct QoP, veracc), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_veracc_constraint_1, - &ASN_PER_MEMB_VERACC_CONSTR_3, 0, "veracc"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_veracc_constraint_1, + &ASN_PER_MEMB_VERACC_CONSTR_3, 0, "veracc"}, {ATF_POINTER, 2, offsetof(struct QoP, maxLocAge), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_maxLocAge_constraint_1, - &ASN_PER_MEMB_MAX_LOC_AGE_CONSTR_4, 0, "maxLocAge"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_maxLocAge_constraint_1, + &ASN_PER_MEMB_MAX_LOC_AGE_CONSTR_4, 0, "maxLocAge"}, {ATF_POINTER, 1, offsetof(struct QoP, delay), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_delay_constraint_1, - &ASN_PER_MEMB_DELAY_CONSTR_5, 0, "delay"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_delay_constraint_1, + &ASN_PER_MEMB_DELAY_CONSTR_5, 0, "delay"}, }; static int asn_MAP_QoP_oms_1[] = {1, 2, 3}; static ber_tlv_tag_t asn_DEF_QoP_tags_1[] = { @@ -196,9 +196,9 @@ asn_TYPE_descriptor_t asn_DEF_QoP = { 0, /* Use generic outmost tag fetcher */ asn_DEF_QoP_tags_1, sizeof(asn_DEF_QoP_tags_1) / sizeof(asn_DEF_QoP_tags_1[0]), /* 1 */ - asn_DEF_QoP_tags_1, /* Same as above */ + asn_DEF_QoP_tags_1, /* Same as above */ sizeof(asn_DEF_QoP_tags_1) / sizeof(asn_DEF_QoP_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_QoP_1, 4, /* Elements count */ &asn_SPC_QoP_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-supl/RequestedAssistData.c b/src/core/libs/supl/asn-supl/RequestedAssistData.c index 3fd81c0c3..c47f1dd4e 100644 --- a/src/core/libs/supl/asn-supl/RequestedAssistData.c +++ b/src/core/libs/supl/asn-supl/RequestedAssistData.c @@ -8,63 +8,63 @@ static asn_TYPE_member_t asn_MBR_RequestedAssistData_1[] = { {ATF_NOFLAGS, 0, offsetof(struct RequestedAssistData, almanacRequested), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "almanacRequested"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "almanacRequested"}, {ATF_NOFLAGS, 0, offsetof(struct RequestedAssistData, utcModelRequested), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "utcModelRequested"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "utcModelRequested"}, {ATF_NOFLAGS, 0, - offsetof(struct RequestedAssistData, ionosphericModelRequested), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ionosphericModelRequested"}, + offsetof(struct RequestedAssistData, ionosphericModelRequested), + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ionosphericModelRequested"}, {ATF_NOFLAGS, 0, - offsetof(struct RequestedAssistData, dgpsCorrectionsRequested), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "dgpsCorrectionsRequested"}, + offsetof(struct RequestedAssistData, dgpsCorrectionsRequested), + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "dgpsCorrectionsRequested"}, {ATF_NOFLAGS, 0, - offsetof(struct RequestedAssistData, referenceLocationRequested), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "referenceLocationRequested"}, + offsetof(struct RequestedAssistData, referenceLocationRequested), + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "referenceLocationRequested"}, {ATF_NOFLAGS, 0, - offsetof(struct RequestedAssistData, referenceTimeRequested), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "referenceTimeRequested"}, + offsetof(struct RequestedAssistData, referenceTimeRequested), + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "referenceTimeRequested"}, {ATF_NOFLAGS, 0, - offsetof(struct RequestedAssistData, acquisitionAssistanceRequested), - (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "acquisitionAssistanceRequested"}, + offsetof(struct RequestedAssistData, acquisitionAssistanceRequested), + (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "acquisitionAssistanceRequested"}, {ATF_NOFLAGS, 0, - offsetof(struct RequestedAssistData, realTimeIntegrityRequested), - (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "realTimeIntegrityRequested"}, + offsetof(struct RequestedAssistData, realTimeIntegrityRequested), + (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "realTimeIntegrityRequested"}, {ATF_NOFLAGS, 0, - offsetof(struct RequestedAssistData, navigationModelRequested), - (ASN_TAG_CLASS_CONTEXT | (8 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "navigationModelRequested"}, + offsetof(struct RequestedAssistData, navigationModelRequested), + (ASN_TAG_CLASS_CONTEXT | (8 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BOOLEAN, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "navigationModelRequested"}, {ATF_POINTER, 1, offsetof(struct RequestedAssistData, navigationModelData), - (ASN_TAG_CLASS_CONTEXT | (9 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_XNavigationModel, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "navigationModelData"}, + (ASN_TAG_CLASS_CONTEXT | (9 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_XNavigationModel, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "navigationModelData"}, }; static int asn_MAP_RequestedAssistData_oms_1[] = {9}; static ber_tlv_tag_t asn_DEF_RequestedAssistData_tags_1[] = { @@ -73,21 +73,21 @@ static asn_TYPE_tag2member_t asn_MAP_RequestedAssistData_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* almanacRequested at 24 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0}, /* utcModelRequested at 25 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, - 0}, /* ionosphericModelRequested at 26 */ + 0}, /* ionosphericModelRequested at 26 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, - 0}, /* dgpsCorrectionsRequested at 27 */ + 0}, /* dgpsCorrectionsRequested at 27 */ {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, - 0}, /* referenceLocationRequested at 28 */ + 0}, /* referenceLocationRequested at 28 */ {(ASN_TAG_CLASS_CONTEXT | (5 << 2)), 5, 0, - 0}, /* referenceTimeRequested at 29 */ + 0}, /* referenceTimeRequested at 29 */ {(ASN_TAG_CLASS_CONTEXT | (6 << 2)), 6, 0, - 0}, /* acquisitionAssistanceRequested at 30 */ + 0}, /* acquisitionAssistanceRequested at 30 */ {(ASN_TAG_CLASS_CONTEXT | (7 << 2)), 7, 0, - 0}, /* realTimeIntegrityRequested at 31 */ + 0}, /* realTimeIntegrityRequested at 31 */ {(ASN_TAG_CLASS_CONTEXT | (8 << 2)), 8, 0, - 0}, /* navigationModelRequested at 32 */ + 0}, /* navigationModelRequested at 32 */ {(ASN_TAG_CLASS_CONTEXT | (9 << 2)), 9, 0, - 0} /* navigationModelData at 33 */ + 0} /* navigationModelData at 33 */ }; static asn_SEQUENCE_specifics_t asn_SPC_RequestedAssistData_specs_1 = { sizeof(struct RequestedAssistData), @@ -119,7 +119,7 @@ asn_TYPE_descriptor_t asn_DEF_RequestedAssistData = { asn_DEF_RequestedAssistData_tags_1, /* Same as above */ sizeof(asn_DEF_RequestedAssistData_tags_1) / sizeof(asn_DEF_RequestedAssistData_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_RequestedAssistData_1, 10, /* Elements count */ &asn_SPC_RequestedAssistData_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-supl/SETAuthKey.c b/src/core/libs/supl/asn-supl/SETAuthKey.c index 191b18c66..0434df179 100644 --- a/src/core/libs/supl/asn-supl/SETAuthKey.c +++ b/src/core/libs/supl/asn-supl/SETAuthKey.c @@ -7,9 +7,9 @@ #include "SETAuthKey.h" static int memb_shortKey_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const BIT_STRING_t *st = (const BIT_STRING_t *)sptr; size_t size; @@ -17,7 +17,7 @@ static int memb_shortKey_constraint_1(asn_TYPE_descriptor_t *td, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -39,15 +39,15 @@ static int memb_shortKey_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_longKey_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const BIT_STRING_t *st = (const BIT_STRING_t *)sptr; size_t size; @@ -55,7 +55,7 @@ static int memb_longKey_constraint_1(asn_TYPE_descriptor_t *td, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -77,7 +77,7 @@ static int memb_longKey_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -102,13 +102,13 @@ static asn_per_constraints_t ASN_PER_TYPE_SET_AUTH_KEY_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_SETAuthKey_1[] = { {ATF_NOFLAGS, 0, offsetof(struct SETAuthKey, choice.shortKey), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BIT_STRING, memb_shortKey_constraint_1, - &ASN_PER_MEMB_SHORT_KEY_CONSTR_2, 0, "shortKey"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BIT_STRING, memb_shortKey_constraint_1, + &ASN_PER_MEMB_SHORT_KEY_CONSTR_2, 0, "shortKey"}, {ATF_NOFLAGS, 0, offsetof(struct SETAuthKey, choice.longKey), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BIT_STRING, memb_longKey_constraint_1, - &ASN_PER_MEMB_LONG_KEY_CONSTR_3, 0, "longKey"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BIT_STRING, memb_longKey_constraint_1, + &ASN_PER_MEMB_LONG_KEY_CONSTR_3, 0, "longKey"}, }; static asn_TYPE_tag2member_t asn_MAP_SETAuthKey_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* shortKey at 17 */ diff --git a/src/core/libs/supl/asn-supl/SETCapabilities.c b/src/core/libs/supl/asn-supl/SETCapabilities.c index 3f2cff2e4..e7f8b8e98 100644 --- a/src/core/libs/supl/asn-supl/SETCapabilities.c +++ b/src/core/libs/supl/asn-supl/SETCapabilities.c @@ -8,22 +8,22 @@ static asn_TYPE_member_t asn_MBR_SETCapabilities_1[] = { {ATF_NOFLAGS, 0, offsetof(struct SETCapabilities, posTechnology), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_PosTechnology, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "posTechnology"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_PosTechnology, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "posTechnology"}, {ATF_NOFLAGS, 0, offsetof(struct SETCapabilities, prefMethod), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_PrefMethod, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "prefMethod"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_PrefMethod, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "prefMethod"}, {ATF_NOFLAGS, 0, offsetof(struct SETCapabilities, posProtocol), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_PosProtocol, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "posProtocol"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_PosProtocol, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "posProtocol"}, }; static ber_tlv_tag_t asn_DEF_SETCapabilities_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -62,7 +62,7 @@ asn_TYPE_descriptor_t asn_DEF_SETCapabilities = { asn_DEF_SETCapabilities_tags_1, /* Same as above */ sizeof(asn_DEF_SETCapabilities_tags_1) / sizeof(asn_DEF_SETCapabilities_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_SETCapabilities_1, 3, /* Elements count */ &asn_SPC_SETCapabilities_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-supl/SETCapabilities.h b/src/core/libs/supl/asn-supl/SETCapabilities.h index f0aab53f7..f24ea5eae 100644 --- a/src/core/libs/supl/asn-supl/SETCapabilities.h +++ b/src/core/libs/supl/asn-supl/SETCapabilities.h @@ -10,9 +10,9 @@ #include /* Including external dependencies */ +#include "PosProtocol.h" #include "PosTechnology.h" #include "PrefMethod.h" -#include "PosProtocol.h" #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-supl/SETId.c b/src/core/libs/supl/asn-supl/SETId.c index e8688d518..d683fc6b7 100644 --- a/src/core/libs/supl/asn-supl/SETId.c +++ b/src/core/libs/supl/asn-supl/SETId.c @@ -22,8 +22,8 @@ static int check_permitted_alphabet_6(const void *sptr) } static int memb_msisdn_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const OCTET_STRING_t *st = (const OCTET_STRING_t *)sptr; size_t size; @@ -31,7 +31,7 @@ static int memb_msisdn_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -45,14 +45,14 @@ static int memb_msisdn_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_mdn_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const OCTET_STRING_t *st = (const OCTET_STRING_t *)sptr; size_t size; @@ -60,7 +60,7 @@ static int memb_mdn_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -74,14 +74,14 @@ static int memb_mdn_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_min_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const BIT_STRING_t *st = (const BIT_STRING_t *)sptr; size_t size; @@ -89,7 +89,7 @@ static int memb_min_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -111,14 +111,14 @@ static int memb_min_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_imsi_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const OCTET_STRING_t *st = (const OCTET_STRING_t *)sptr; size_t size; @@ -126,7 +126,7 @@ static int memb_imsi_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -140,14 +140,14 @@ static int memb_imsi_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_nai_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const IA5String_t *st = (const IA5String_t *)sptr; size_t size; @@ -155,7 +155,7 @@ static int memb_nai_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -169,7 +169,7 @@ static int memb_nai_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -212,30 +212,30 @@ static asn_per_constraints_t ASN_PER_TYPE_SET_ID_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_SETId_1[] = { {ATF_NOFLAGS, 0, offsetof(struct SETId, choice.msisdn), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_OCTET_STRING, memb_msisdn_constraint_1, - &ASN_PER_MEMB_MSISDN_CONSTR_2, 0, "msisdn"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_OCTET_STRING, memb_msisdn_constraint_1, + &ASN_PER_MEMB_MSISDN_CONSTR_2, 0, "msisdn"}, {ATF_NOFLAGS, 0, offsetof(struct SETId, choice.mdn), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_OCTET_STRING, memb_mdn_constraint_1, &ASN_PER_MEMB_MDN_CONSTR_3, - 0, "mdn"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_OCTET_STRING, memb_mdn_constraint_1, &ASN_PER_MEMB_MDN_CONSTR_3, + 0, "mdn"}, {ATF_NOFLAGS, 0, offsetof(struct SETId, choice.min), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_BIT_STRING, memb_min_constraint_1, &ASN_PER_MEMB_MIN_CONSTR_4, 0, - "min"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_BIT_STRING, memb_min_constraint_1, &ASN_PER_MEMB_MIN_CONSTR_4, 0, + "min"}, {ATF_NOFLAGS, 0, offsetof(struct SETId, choice.imsi), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_OCTET_STRING, memb_imsi_constraint_1, &ASN_PER_MEMB_IMSI_CONSTR_5, - 0, "imsi"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_OCTET_STRING, memb_imsi_constraint_1, &ASN_PER_MEMB_IMSI_CONSTR_5, + 0, "imsi"}, {ATF_NOFLAGS, 0, offsetof(struct SETId, choice.nai), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_IA5String, memb_nai_constraint_1, &ASN_PER_MEMB_NAI_CONSTR_6, 0, - "nai"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_IA5String, memb_nai_constraint_1, &ASN_PER_MEMB_NAI_CONSTR_6, 0, + "nai"}, {ATF_NOFLAGS, 0, offsetof(struct SETId, choice.iPAddress), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), +1, /* EXPLICIT tag at current level */ - &asn_DEF_IPAddress, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "iPAddress"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), +1, /* EXPLICIT tag at current level */ + &asn_DEF_IPAddress, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "iPAddress"}, }; static asn_TYPE_tag2member_t asn_MAP_SETId_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* msisdn at 22 */ diff --git a/src/core/libs/supl/asn-supl/SETId.h b/src/core/libs/supl/asn-supl/SETId.h index 4325e0466..68f77a71f 100644 --- a/src/core/libs/supl/asn-supl/SETId.h +++ b/src/core/libs/supl/asn-supl/SETId.h @@ -10,10 +10,10 @@ #include /* Including external dependencies */ -#include +#include "IPAddress.h" #include #include -#include "IPAddress.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-supl/SLPAddress.c b/src/core/libs/supl/asn-supl/SLPAddress.c index fa06110ea..98f213cae 100644 --- a/src/core/libs/supl/asn-supl/SLPAddress.c +++ b/src/core/libs/supl/asn-supl/SLPAddress.c @@ -14,15 +14,15 @@ static asn_per_constraints_t ASN_PER_TYPE_SLP_ADDRESS_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_SLPAddress_1[] = { {ATF_NOFLAGS, 0, offsetof(struct SLPAddress, choice.iPAddress), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), +1, /* EXPLICIT tag at current level */ - &asn_DEF_IPAddress, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "iPAddress"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), +1, /* EXPLICIT tag at current level */ + &asn_DEF_IPAddress, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "iPAddress"}, {ATF_NOFLAGS, 0, offsetof(struct SLPAddress, choice.fQDN), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_FQDN, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "fQDN"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_FQDN, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "fQDN"}, }; static asn_TYPE_tag2member_t asn_MAP_SLPAddress_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* iPAddress at 44 */ diff --git a/src/core/libs/supl/asn-supl/SLPAddress.h b/src/core/libs/supl/asn-supl/SLPAddress.h index b11440882..b4b89457c 100644 --- a/src/core/libs/supl/asn-supl/SLPAddress.h +++ b/src/core/libs/supl/asn-supl/SLPAddress.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include "IPAddress.h" #include "FQDN.h" +#include "IPAddress.h" #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-supl/SLPMode.c b/src/core/libs/supl/asn-supl/SLPMode.c index 242f06f91..c178488d3 100644 --- a/src/core/libs/supl/asn-supl/SLPMode.c +++ b/src/core/libs/supl/asn-supl/SLPMode.c @@ -7,7 +7,7 @@ #include "SLPMode.h" int SLPMode_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { /* Replace with underlying type checker */ td->check_constraints = asn_DEF_ENUMERATED.check_constraints; @@ -38,67 +38,67 @@ static void SLPMode_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void SLPMode_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { SLPMode_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int SLPMode_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { SLPMode_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t SLPMode_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, int tag_mode) { SLPMode_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t SLPMode_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { SLPMode_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t SLPMode_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { SLPMode_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t SLPMode_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { SLPMode_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t SLPMode_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { SLPMode_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t SLPMode_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { SLPMode_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); @@ -141,7 +141,7 @@ asn_TYPE_descriptor_t asn_DEF_SLPMode = { 0, /* Use generic outmost tag fetcher */ asn_DEF_SLPMode_tags_1, sizeof(asn_DEF_SLPMode_tags_1) / sizeof(asn_DEF_SLPMode_tags_1[0]), /* 1 */ - asn_DEF_SLPMode_tags_1, /* Same as above */ + asn_DEF_SLPMode_tags_1, /* Same as above */ sizeof(asn_DEF_SLPMode_tags_1) / sizeof(asn_DEF_SLPMode_tags_1[0]), /* 1 */ &ASN_PER_TYPE_SLP_MODE_CONSTR_1, 0, diff --git a/src/core/libs/supl/asn-supl/SUPLEND.c b/src/core/libs/supl/asn-supl/SUPLEND.c index e38c58084..406a426ba 100644 --- a/src/core/libs/supl/asn-supl/SUPLEND.c +++ b/src/core/libs/supl/asn-supl/SUPLEND.c @@ -8,20 +8,20 @@ static asn_TYPE_member_t asn_MBR_SUPLEND_1[] = { {ATF_POINTER, 3, offsetof(struct SUPLEND, position), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Position, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "position"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Position, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "position"}, {ATF_POINTER, 2, offsetof(struct SUPLEND, statusCode), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_StatusCode, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "statusCode"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_StatusCode, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "statusCode"}, {ATF_POINTER, 1, offsetof(struct SUPLEND, ver), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Ver, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ver"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Ver, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ver"}, }; static int asn_MAP_SUPLEND_oms_1[] = {0, 1, 2}; static ber_tlv_tag_t asn_DEF_SUPLEND_tags_1[] = { @@ -57,9 +57,9 @@ asn_TYPE_descriptor_t asn_DEF_SUPLEND = { 0, /* Use generic outmost tag fetcher */ asn_DEF_SUPLEND_tags_1, sizeof(asn_DEF_SUPLEND_tags_1) / sizeof(asn_DEF_SUPLEND_tags_1[0]), /* 1 */ - asn_DEF_SUPLEND_tags_1, /* Same as above */ + asn_DEF_SUPLEND_tags_1, /* Same as above */ sizeof(asn_DEF_SUPLEND_tags_1) / sizeof(asn_DEF_SUPLEND_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_SUPLEND_1, 3, /* Elements count */ &asn_SPC_SUPLEND_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-supl/SUPLINIT.c b/src/core/libs/supl/asn-supl/SUPLINIT.c index 2455edde4..2eef45c35 100644 --- a/src/core/libs/supl/asn-supl/SUPLINIT.c +++ b/src/core/libs/supl/asn-supl/SUPLINIT.c @@ -8,42 +8,42 @@ static asn_TYPE_member_t asn_MBR_SUPLINIT_1[] = { {ATF_NOFLAGS, 0, offsetof(struct SUPLINIT, posMethod), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_PosMethod, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "posMethod"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_PosMethod, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "posMethod"}, {ATF_POINTER, 3, offsetof(struct SUPLINIT, notification), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Notification, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "notification"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Notification, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "notification"}, {ATF_POINTER, 2, offsetof(struct SUPLINIT, sLPAddress), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), +1, /* EXPLICIT tag at current level */ - &asn_DEF_SLPAddress, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "sLPAddress"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), +1, /* EXPLICIT tag at current level */ + &asn_DEF_SLPAddress, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "sLPAddress"}, {ATF_POINTER, 1, offsetof(struct SUPLINIT, qoP), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_QoP, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "qoP"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_QoP, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "qoP"}, {ATF_NOFLAGS, 0, offsetof(struct SUPLINIT, sLPMode), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SLPMode, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "sLPMode"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SLPMode, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "sLPMode"}, {ATF_POINTER, 2, offsetof(struct SUPLINIT, mAC), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_MAC, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "mAC"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_MAC, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "mAC"}, {ATF_POINTER, 1, offsetof(struct SUPLINIT, keyIdentity), - (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_KeyIdentity, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "keyIdentity"}, + (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_KeyIdentity, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "keyIdentity"}, }; static int asn_MAP_SUPLINIT_oms_1[] = {1, 2, 3, 5, 6}; static ber_tlv_tag_t asn_DEF_SUPLINIT_tags_1[] = { diff --git a/src/core/libs/supl/asn-supl/SUPLINIT.h b/src/core/libs/supl/asn-supl/SUPLINIT.h index c79b4e04f..8cf65ac23 100644 --- a/src/core/libs/supl/asn-supl/SUPLINIT.h +++ b/src/core/libs/supl/asn-supl/SUPLINIT.h @@ -10,10 +10,10 @@ #include /* Including external dependencies */ +#include "KeyIdentity.h" +#include "MAC.h" #include "PosMethod.h" #include "SLPMode.h" -#include "MAC.h" -#include "KeyIdentity.h" #include #ifdef __cplusplus @@ -54,8 +54,8 @@ extern "C" /* Referred external types */ #include "Notification.h" -#include "SLPAddress.h" #include "QoP.h" +#include "SLPAddress.h" #endif /* _SUPLINIT_H_ */ #include diff --git a/src/core/libs/supl/asn-supl/SUPLPOS.c b/src/core/libs/supl/asn-supl/SUPLPOS.c index 1f5e63c53..b04ced705 100644 --- a/src/core/libs/supl/asn-supl/SUPLPOS.c +++ b/src/core/libs/supl/asn-supl/SUPLPOS.c @@ -8,15 +8,15 @@ static asn_TYPE_member_t asn_MBR_SUPLPOS_1[] = { {ATF_NOFLAGS, 0, offsetof(struct SUPLPOS, posPayLoad), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), +1, /* EXPLICIT tag at current level */ - &asn_DEF_PosPayLoad, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "posPayLoad"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), +1, /* EXPLICIT tag at current level */ + &asn_DEF_PosPayLoad, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "posPayLoad"}, {ATF_POINTER, 1, offsetof(struct SUPLPOS, velocity), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), +1, /* EXPLICIT tag at current level */ - &asn_DEF_Velocity, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "velocity"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), +1, /* EXPLICIT tag at current level */ + &asn_DEF_Velocity, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "velocity"}, }; static int asn_MAP_SUPLPOS_oms_1[] = {1}; static ber_tlv_tag_t asn_DEF_SUPLPOS_tags_1[] = { @@ -51,9 +51,9 @@ asn_TYPE_descriptor_t asn_DEF_SUPLPOS = { 0, /* Use generic outmost tag fetcher */ asn_DEF_SUPLPOS_tags_1, sizeof(asn_DEF_SUPLPOS_tags_1) / sizeof(asn_DEF_SUPLPOS_tags_1[0]), /* 1 */ - asn_DEF_SUPLPOS_tags_1, /* Same as above */ + asn_DEF_SUPLPOS_tags_1, /* Same as above */ sizeof(asn_DEF_SUPLPOS_tags_1) / sizeof(asn_DEF_SUPLPOS_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_SUPLPOS_1, 2, /* Elements count */ &asn_SPC_SUPLPOS_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-supl/SUPLPOSINIT.c b/src/core/libs/supl/asn-supl/SUPLPOSINIT.c index b8e38cf04..a75051c0e 100644 --- a/src/core/libs/supl/asn-supl/SUPLPOSINIT.c +++ b/src/core/libs/supl/asn-supl/SUPLPOSINIT.c @@ -8,37 +8,37 @@ static asn_TYPE_member_t asn_MBR_SUPLPOSINIT_1[] = { {ATF_NOFLAGS, 0, offsetof(struct SUPLPOSINIT, sETCapabilities), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SETCapabilities, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "sETCapabilities"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SETCapabilities, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "sETCapabilities"}, {ATF_POINTER, 1, offsetof(struct SUPLPOSINIT, requestedAssistData), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_RequestedAssistData, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "requestedAssistData"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_RequestedAssistData, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "requestedAssistData"}, {ATF_NOFLAGS, 0, offsetof(struct SUPLPOSINIT, locationId), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_LocationId, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "locationId"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_LocationId, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "locationId"}, {ATF_POINTER, 3, offsetof(struct SUPLPOSINIT, position), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Position, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "position"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Position, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "position"}, {ATF_POINTER, 2, offsetof(struct SUPLPOSINIT, sUPLPOS), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SUPLPOS, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "sUPLPOS"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SUPLPOS, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "sUPLPOS"}, {ATF_POINTER, 1, offsetof(struct SUPLPOSINIT, ver), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Ver, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "ver"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Ver, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "ver"}, }; static int asn_MAP_SUPLPOSINIT_oms_1[] = {1, 3, 4, 5}; static ber_tlv_tag_t asn_DEF_SUPLPOSINIT_tags_1[] = { @@ -46,7 +46,7 @@ static ber_tlv_tag_t asn_DEF_SUPLPOSINIT_tags_1[] = { static asn_TYPE_tag2member_t asn_MAP_SUPLPOSINIT_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* sETCapabilities at 15 */ {(ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, - 0}, /* requestedAssistData at 16 */ + 0}, /* requestedAssistData at 16 */ {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0}, /* locationId at 17 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, 0}, /* position at 18 */ {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, 0}, /* sUPLPOS at 19 */ diff --git a/src/core/libs/supl/asn-supl/SUPLPOSINIT.h b/src/core/libs/supl/asn-supl/SUPLPOSINIT.h index 789842aea..5621ab110 100644 --- a/src/core/libs/supl/asn-supl/SUPLPOSINIT.h +++ b/src/core/libs/supl/asn-supl/SUPLPOSINIT.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include "SETCapabilities.h" #include "LocationId.h" +#include "SETCapabilities.h" #include "Ver.h" #include @@ -51,8 +51,8 @@ extern "C" #endif /* Referred external types */ -#include "RequestedAssistData.h" #include "Position.h" +#include "RequestedAssistData.h" #include "SUPLPOS.h" #endif /* _SUPLPOSINIT_H_ */ diff --git a/src/core/libs/supl/asn-supl/SUPLRESPONSE.c b/src/core/libs/supl/asn-supl/SUPLRESPONSE.c index c6f383aa8..0700f447d 100644 --- a/src/core/libs/supl/asn-supl/SUPLRESPONSE.c +++ b/src/core/libs/supl/asn-supl/SUPLRESPONSE.c @@ -8,26 +8,26 @@ static asn_TYPE_member_t asn_MBR_SUPLRESPONSE_1[] = { {ATF_NOFLAGS, 0, offsetof(struct SUPLRESPONSE, posMethod), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_PosMethod, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "posMethod"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_PosMethod, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "posMethod"}, {ATF_POINTER, 3, offsetof(struct SUPLRESPONSE, sLPAddress), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), +1, /* EXPLICIT tag at current level */ - &asn_DEF_SLPAddress, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "sLPAddress"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), +1, /* EXPLICIT tag at current level */ + &asn_DEF_SLPAddress, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "sLPAddress"}, {ATF_POINTER, 2, offsetof(struct SUPLRESPONSE, sETAuthKey), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), +1, /* EXPLICIT tag at current level */ - &asn_DEF_SETAuthKey, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "sETAuthKey"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), +1, /* EXPLICIT tag at current level */ + &asn_DEF_SETAuthKey, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "sETAuthKey"}, {ATF_POINTER, 1, offsetof(struct SUPLRESPONSE, keyIdentity4), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_KeyIdentity4, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "keyIdentity4"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_KeyIdentity4, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "keyIdentity4"}, }; static int asn_MAP_SUPLRESPONSE_oms_1[] = {1, 2, 3}; static ber_tlv_tag_t asn_DEF_SUPLRESPONSE_tags_1[] = { diff --git a/src/core/libs/supl/asn-supl/SUPLRESPONSE.h b/src/core/libs/supl/asn-supl/SUPLRESPONSE.h index 1dc35f771..fa77504cd 100644 --- a/src/core/libs/supl/asn-supl/SUPLRESPONSE.h +++ b/src/core/libs/supl/asn-supl/SUPLRESPONSE.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include "PosMethod.h" #include "KeyIdentity4.h" +#include "PosMethod.h" #include #ifdef __cplusplus @@ -47,8 +47,8 @@ extern "C" #endif /* Referred external types */ -#include "SLPAddress.h" #include "SETAuthKey.h" +#include "SLPAddress.h" #endif /* _SUPLRESPONSE_H_ */ #include diff --git a/src/core/libs/supl/asn-supl/SUPLSTART.c b/src/core/libs/supl/asn-supl/SUPLSTART.c index b1c8f3b04..01d5e8846 100644 --- a/src/core/libs/supl/asn-supl/SUPLSTART.c +++ b/src/core/libs/supl/asn-supl/SUPLSTART.c @@ -8,21 +8,21 @@ static asn_TYPE_member_t asn_MBR_SUPLSTART_1[] = { {ATF_NOFLAGS, 0, offsetof(struct SUPLSTART, sETCapabilities), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SETCapabilities, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "sETCapabilities"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SETCapabilities, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "sETCapabilities"}, {ATF_NOFLAGS, 0, offsetof(struct SUPLSTART, locationId), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_LocationId, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "locationId"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_LocationId, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "locationId"}, {ATF_POINTER, 1, offsetof(struct SUPLSTART, qoP), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_QoP, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "qoP"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_QoP, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "qoP"}, }; static int asn_MAP_SUPLSTART_oms_1[] = {2}; static ber_tlv_tag_t asn_DEF_SUPLSTART_tags_1[] = { diff --git a/src/core/libs/supl/asn-supl/SUPLSTART.h b/src/core/libs/supl/asn-supl/SUPLSTART.h index 69fd8d9bc..7683c674f 100644 --- a/src/core/libs/supl/asn-supl/SUPLSTART.h +++ b/src/core/libs/supl/asn-supl/SUPLSTART.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include "SETCapabilities.h" #include "LocationId.h" +#include "SETCapabilities.h" #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-supl/SatelliteInfo.c b/src/core/libs/supl/asn-supl/SatelliteInfo.c index 1aa2225ea..6e64453ef 100644 --- a/src/core/libs/supl/asn-supl/SatelliteInfo.c +++ b/src/core/libs/supl/asn-supl/SatelliteInfo.c @@ -14,10 +14,10 @@ static asn_per_constraints_t ASN_PER_TYPE_SATELLITE_INFO_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_SatelliteInfo_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, - &asn_DEF_SatelliteInfoElement, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_SatelliteInfoElement, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_SatelliteInfo_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-supl/SatelliteInfoElement.c b/src/core/libs/supl/asn-supl/SatelliteInfoElement.c index 670b565d7..7eb9aff0e 100644 --- a/src/core/libs/supl/asn-supl/SatelliteInfoElement.c +++ b/src/core/libs/supl/asn-supl/SatelliteInfoElement.c @@ -7,15 +7,15 @@ #include "SatelliteInfoElement.h" static int memb_satId_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,21 +29,21 @@ static int memb_satId_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_iODE_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -57,7 +57,7 @@ static int memb_iODE_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -76,13 +76,13 @@ static asn_per_constraints_t ASN_PER_MEMB_I_ODE_CONSTR_3 = { }; static asn_TYPE_member_t asn_MBR_SatelliteInfoElement_1[] = { {ATF_NOFLAGS, 0, offsetof(struct SatelliteInfoElement, satId), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_satId_constraint_1, - &ASN_PER_MEMB_SAT_ID_CONSTR_2, 0, "satId"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_satId_constraint_1, + &ASN_PER_MEMB_SAT_ID_CONSTR_2, 0, "satId"}, {ATF_NOFLAGS, 0, offsetof(struct SatelliteInfoElement, iODE), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_iODE_constraint_1, - &ASN_PER_MEMB_I_ODE_CONSTR_3, 0, "iODE"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_iODE_constraint_1, + &ASN_PER_MEMB_I_ODE_CONSTR_3, 0, "iODE"}, }; static ber_tlv_tag_t asn_DEF_SatelliteInfoElement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -120,7 +120,7 @@ asn_TYPE_descriptor_t asn_DEF_SatelliteInfoElement = { asn_DEF_SatelliteInfoElement_tags_1, /* Same as above */ sizeof(asn_DEF_SatelliteInfoElement_tags_1) / sizeof(asn_DEF_SatelliteInfoElement_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_SatelliteInfoElement_1, 2, /* Elements count */ &asn_SPC_SatelliteInfoElement_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-supl/SessionID.c b/src/core/libs/supl/asn-supl/SessionID.c index e2c00b553..d49ea8a74 100644 --- a/src/core/libs/supl/asn-supl/SessionID.c +++ b/src/core/libs/supl/asn-supl/SessionID.c @@ -8,17 +8,17 @@ static asn_TYPE_member_t asn_MBR_SessionID_1[] = { {ATF_POINTER, 2, offsetof(struct SessionID, setSessionID), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SetSessionID, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "setSessionID"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SetSessionID, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "setSessionID"}, {ATF_POINTER, 1, offsetof(struct SessionID, slpSessionID), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SlpSessionID, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "slpSessionID"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SlpSessionID, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "slpSessionID"}, }; static int asn_MAP_SessionID_oms_1[] = {0, 1}; static ber_tlv_tag_t asn_DEF_SessionID_tags_1[] = { diff --git a/src/core/libs/supl/asn-supl/SetSessionID.c b/src/core/libs/supl/asn-supl/SetSessionID.c index 5ad191d9b..4c34ac941 100644 --- a/src/core/libs/supl/asn-supl/SetSessionID.c +++ b/src/core/libs/supl/asn-supl/SetSessionID.c @@ -7,16 +7,16 @@ #include "SetSessionID.h" static int memb_sessionId_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,7 +30,7 @@ static int memb_sessionId_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -43,14 +43,14 @@ static asn_per_constraints_t ASN_PER_MEMB_SESSION_ID_CONSTR_2 = { }; static asn_TYPE_member_t asn_MBR_SetSessionID_1[] = { {ATF_NOFLAGS, 0, offsetof(struct SetSessionID, sessionId), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_sessionId_constraint_1, - &ASN_PER_MEMB_SESSION_ID_CONSTR_2, 0, "sessionId"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_sessionId_constraint_1, + &ASN_PER_MEMB_SESSION_ID_CONSTR_2, 0, "sessionId"}, {ATF_NOFLAGS, 0, offsetof(struct SetSessionID, setId), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), +1, /* EXPLICIT tag at current level */ - &asn_DEF_SETId, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "setId"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), +1, /* EXPLICIT tag at current level */ + &asn_DEF_SETId, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "setId"}, }; static ber_tlv_tag_t asn_DEF_SetSessionID_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-supl/SetSessionID.h b/src/core/libs/supl/asn-supl/SetSessionID.h index b8f17b5a9..d2e032627 100644 --- a/src/core/libs/supl/asn-supl/SetSessionID.h +++ b/src/core/libs/supl/asn-supl/SetSessionID.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include #include "SETId.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-supl/SlpSessionID.c b/src/core/libs/supl/asn-supl/SlpSessionID.c index 2eb00447c..5dca3c145 100644 --- a/src/core/libs/supl/asn-supl/SlpSessionID.c +++ b/src/core/libs/supl/asn-supl/SlpSessionID.c @@ -7,9 +7,9 @@ #include "SlpSessionID.h" static int memb_sessionID_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const OCTET_STRING_t *st = (const OCTET_STRING_t *)sptr; size_t size; @@ -17,7 +17,7 @@ static int memb_sessionID_constraint_1(asn_TYPE_descriptor_t *td, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -31,7 +31,7 @@ static int memb_sessionID_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -44,14 +44,14 @@ static asn_per_constraints_t ASN_PER_MEMB_SESSION_ID_CONSTR_2 = { }; static asn_TYPE_member_t asn_MBR_SlpSessionID_1[] = { {ATF_NOFLAGS, 0, offsetof(struct SlpSessionID, sessionID), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_OCTET_STRING, memb_sessionID_constraint_1, - &ASN_PER_MEMB_SESSION_ID_CONSTR_2, 0, "sessionID"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_OCTET_STRING, memb_sessionID_constraint_1, + &ASN_PER_MEMB_SESSION_ID_CONSTR_2, 0, "sessionID"}, {ATF_NOFLAGS, 0, offsetof(struct SlpSessionID, slpId), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), +1, /* EXPLICIT tag at current level */ - &asn_DEF_SLPAddress, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "slpId"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), +1, /* EXPLICIT tag at current level */ + &asn_DEF_SLPAddress, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "slpId"}, }; static ber_tlv_tag_t asn_DEF_SlpSessionID_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-supl/SlpSessionID.h b/src/core/libs/supl/asn-supl/SlpSessionID.h index ba1662c9f..df43681cc 100644 --- a/src/core/libs/supl/asn-supl/SlpSessionID.h +++ b/src/core/libs/supl/asn-supl/SlpSessionID.h @@ -10,8 +10,8 @@ #include /* Including external dependencies */ -#include #include "SLPAddress.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-supl/Status.c b/src/core/libs/supl/asn-supl/Status.c index 4a38f4fc0..09ad2e871 100644 --- a/src/core/libs/supl/asn-supl/Status.c +++ b/src/core/libs/supl/asn-supl/Status.c @@ -7,7 +7,7 @@ #include "Status.h" int Status_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { /* Replace with underlying type checker */ td->check_constraints = asn_DEF_ENUMERATED.check_constraints; @@ -44,60 +44,60 @@ void Status_free(asn_TYPE_descriptor_t *td, void *struct_ptr, int contents_only) } int Status_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { Status_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t Status_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, int tag_mode) { Status_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t Status_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { Status_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t Status_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { Status_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t Status_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { Status_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t Status_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { Status_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t Status_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { Status_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); @@ -144,7 +144,7 @@ asn_TYPE_descriptor_t asn_DEF_Status = { 0, /* Use generic outmost tag fetcher */ asn_DEF_Status_tags_1, sizeof(asn_DEF_Status_tags_1) / sizeof(asn_DEF_Status_tags_1[0]), /* 1 */ - asn_DEF_Status_tags_1, /* Same as above */ + asn_DEF_Status_tags_1, /* Same as above */ sizeof(asn_DEF_Status_tags_1) / sizeof(asn_DEF_Status_tags_1[0]), /* 1 */ &ASN_PER_TYPE_STATUS_CONSTR_1, 0, diff --git a/src/core/libs/supl/asn-supl/StatusCode.c b/src/core/libs/supl/asn-supl/StatusCode.c index d95c684f8..456b60fca 100644 --- a/src/core/libs/supl/asn-supl/StatusCode.c +++ b/src/core/libs/supl/asn-supl/StatusCode.c @@ -7,7 +7,7 @@ #include "StatusCode.h" int StatusCode_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { /* Replace with underlying type checker */ td->check_constraints = asn_DEF_ENUMERATED.check_constraints; @@ -38,69 +38,69 @@ static void StatusCode_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void StatusCode_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { StatusCode_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int StatusCode_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { StatusCode_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t StatusCode_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { StatusCode_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t StatusCode_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { StatusCode_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t StatusCode_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, const char *opt_mname, + const void *bufptr, size_t size) { StatusCode_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t StatusCode_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { StatusCode_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t StatusCode_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { StatusCode_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t StatusCode_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { StatusCode_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-supl/TGSN.c b/src/core/libs/supl/asn-supl/TGSN.c index a3fa10544..cb58047e2 100644 --- a/src/core/libs/supl/asn-supl/TGSN.c +++ b/src/core/libs/supl/asn-supl/TGSN.c @@ -7,14 +7,14 @@ #include "TGSN.h" int TGSN_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int TGSN_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -61,60 +61,60 @@ void TGSN_free(asn_TYPE_descriptor_t *td, void *struct_ptr, int contents_only) } int TGSN_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { TGSN_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t TGSN_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, int tag_mode) { TGSN_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t TGSN_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { TGSN_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t TGSN_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { TGSN_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t TGSN_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { TGSN_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t TGSN_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { TGSN_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t TGSN_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { TGSN_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); @@ -143,7 +143,7 @@ asn_TYPE_descriptor_t asn_DEF_TGSN = { 0, /* Use generic outmost tag fetcher */ asn_DEF_TGSN_tags_1, sizeof(asn_DEF_TGSN_tags_1) / sizeof(asn_DEF_TGSN_tags_1[0]), /* 1 */ - asn_DEF_TGSN_tags_1, /* Same as above */ + asn_DEF_TGSN_tags_1, /* Same as above */ sizeof(asn_DEF_TGSN_tags_1) / sizeof(asn_DEF_TGSN_tags_1[0]), /* 1 */ &ASN_PER_TYPE_TGSN_CONSTR_1, 0, diff --git a/src/core/libs/supl/asn-supl/TimeslotISCP-List.c b/src/core/libs/supl/asn-supl/TimeslotISCP-List.c index a3630541f..7fcb763c8 100644 --- a/src/core/libs/supl/asn-supl/TimeslotISCP-List.c +++ b/src/core/libs/supl/asn-supl/TimeslotISCP-List.c @@ -14,10 +14,10 @@ static asn_per_constraints_t ASN_PER_TYPE_TIMESLOT_ISCP_LIST_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_TimeslotISCP_List_1[] = { {ATF_POINTER, 0, 0, (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)), 0, - &asn_DEF_TimeslotISCP, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, ""}, + &asn_DEF_TimeslotISCP, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, ""}, }; static ber_tlv_tag_t asn_DEF_TimeslotISCP_List_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; diff --git a/src/core/libs/supl/asn-supl/TimeslotISCP.c b/src/core/libs/supl/asn-supl/TimeslotISCP.c index 0e3e84ee5..27d3bb50c 100644 --- a/src/core/libs/supl/asn-supl/TimeslotISCP.c +++ b/src/core/libs/supl/asn-supl/TimeslotISCP.c @@ -7,15 +7,15 @@ #include "TimeslotISCP.h" int TimeslotISCP_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ int TimeslotISCP_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -56,74 +56,74 @@ static void TimeslotISCP_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) } void TimeslotISCP_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { TimeslotISCP_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int TimeslotISCP_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, void *app_key) { TimeslotISCP_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t TimeslotISCP_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { TimeslotISCP_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t TimeslotISCP_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { TimeslotISCP_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t TimeslotISCP_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, const char *opt_mname, + const void *bufptr, size_t size) { TimeslotISCP_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t TimeslotISCP_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { TimeslotISCP_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t TimeslotISCP_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { TimeslotISCP_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t TimeslotISCP_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { TimeslotISCP_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-supl/UARFCN.c b/src/core/libs/supl/asn-supl/UARFCN.c index f48704e63..a7719dd0f 100644 --- a/src/core/libs/supl/asn-supl/UARFCN.c +++ b/src/core/libs/supl/asn-supl/UARFCN.c @@ -7,14 +7,14 @@ #include "UARFCN.h" int UARFCN_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -28,7 +28,7 @@ int UARFCN_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -61,60 +61,60 @@ void UARFCN_free(asn_TYPE_descriptor_t *td, void *struct_ptr, int contents_only) } int UARFCN_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { UARFCN_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t UARFCN_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, int tag_mode) { UARFCN_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t UARFCN_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { UARFCN_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t UARFCN_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { UARFCN_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t UARFCN_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { UARFCN_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t UARFCN_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { UARFCN_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t UARFCN_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { UARFCN_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); @@ -143,7 +143,7 @@ asn_TYPE_descriptor_t asn_DEF_UARFCN = { 0, /* Use generic outmost tag fetcher */ asn_DEF_UARFCN_tags_1, sizeof(asn_DEF_UARFCN_tags_1) / sizeof(asn_DEF_UARFCN_tags_1[0]), /* 1 */ - asn_DEF_UARFCN_tags_1, /* Same as above */ + asn_DEF_UARFCN_tags_1, /* Same as above */ sizeof(asn_DEF_UARFCN_tags_1) / sizeof(asn_DEF_UARFCN_tags_1[0]), /* 1 */ &ASN_PER_TYPE_UARFCN_CONSTR_1, 0, diff --git a/src/core/libs/supl/asn-supl/ULP-PDU.c b/src/core/libs/supl/asn-supl/ULP-PDU.c index 7440b0479..7cbfe489f 100644 --- a/src/core/libs/supl/asn-supl/ULP-PDU.c +++ b/src/core/libs/supl/asn-supl/ULP-PDU.c @@ -7,15 +7,15 @@ #include "ULP-PDU.h" static int memb_length_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ static int memb_length_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -42,24 +42,24 @@ static asn_per_constraints_t ASN_PER_MEMB_LENGTH_CONSTR_2 = { }; static asn_TYPE_member_t asn_MBR_ULP_PDU_1[] = { {ATF_NOFLAGS, 0, offsetof(struct ULP_PDU, length), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_length_constraint_1, - &ASN_PER_MEMB_LENGTH_CONSTR_2, 0, "length"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_length_constraint_1, + &ASN_PER_MEMB_LENGTH_CONSTR_2, 0, "length"}, {ATF_NOFLAGS, 0, offsetof(struct ULP_PDU, version), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Version, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "version"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Version, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "version"}, {ATF_NOFLAGS, 0, offsetof(struct ULP_PDU, sessionID), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SessionID, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "sessionID"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SessionID, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "sessionID"}, {ATF_NOFLAGS, 0, offsetof(struct ULP_PDU, message), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), +1, /* EXPLICIT tag at current level */ - &asn_DEF_UlpMessage, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "message"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), +1, /* EXPLICIT tag at current level */ + &asn_DEF_UlpMessage, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "message"}, }; static ber_tlv_tag_t asn_DEF_ULP_PDU_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -95,9 +95,9 @@ asn_TYPE_descriptor_t asn_DEF_ULP_PDU = { 0, /* Use generic outmost tag fetcher */ asn_DEF_ULP_PDU_tags_1, sizeof(asn_DEF_ULP_PDU_tags_1) / sizeof(asn_DEF_ULP_PDU_tags_1[0]), /* 1 */ - asn_DEF_ULP_PDU_tags_1, /* Same as above */ + asn_DEF_ULP_PDU_tags_1, /* Same as above */ sizeof(asn_DEF_ULP_PDU_tags_1) / sizeof(asn_DEF_ULP_PDU_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_ULP_PDU_1, 4, /* Elements count */ &asn_SPC_ULP_PDU_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-supl/ULP-PDU.h b/src/core/libs/supl/asn-supl/ULP-PDU.h index 2200a42af..beac31465 100644 --- a/src/core/libs/supl/asn-supl/ULP-PDU.h +++ b/src/core/libs/supl/asn-supl/ULP-PDU.h @@ -10,10 +10,10 @@ #include /* Including external dependencies */ -#include -#include "Version.h" #include "SessionID.h" #include "UlpMessage.h" +#include "Version.h" +#include #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-supl/UTCTime.c b/src/core/libs/supl/asn-supl/UTCTime.c index 9108201c9..d0c002f4f 100644 --- a/src/core/libs/supl/asn-supl/UTCTime.c +++ b/src/core/libs/supl/asn-supl/UTCTime.c @@ -2,9 +2,9 @@ * Copyright (c) 2003, 2004 Lev Walkin . All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ -#include -#include #include +#include +#include #include #ifdef __CYGWIN__ @@ -57,7 +57,7 @@ asn_TYPE_descriptor_t asn_DEF_UTCTime = { * Check that the time looks like the time. */ int UTCTime_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { const UTCTime_t *st = (const UTCTime_t *)sptr; time_t tloc; @@ -67,8 +67,8 @@ int UTCTime_constraint(asn_TYPE_descriptor_t *td, const void *sptr, if (tloc == -1 && errno != EPERM) { _ASN_CTFAIL(app_key, td, sptr, - "%s: Invalid time format: %s (%s:%d)", td->name, - strerror(errno), __FILE__, __LINE__); + "%s: Invalid time format: %s (%s:%d)", td->name, + strerror(errno), __FILE__, __LINE__); return -1; } @@ -78,8 +78,8 @@ int UTCTime_constraint(asn_TYPE_descriptor_t *td, const void *sptr, #ifndef __ASN_INTERNAL_TEST_MODE__ asn_enc_rval_t UTCTime_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { if (flags & XER_F_CANONICAL) { @@ -96,21 +96,21 @@ asn_enc_rval_t UTCTime_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, if (!ut) _ASN_ENCODE_FAILED; rv = OCTET_STRING_encode_xer_utf8(td, sptr, ilevel, flags, cb, - app_key); + app_key); OCTET_STRING_free(&asn_DEF_UTCTime, ut, 0); return rv; } else { return OCTET_STRING_encode_xer_utf8(td, sptr, ilevel, flags, cb, - app_key); + app_key); } } #endif /* __ASN_INTERNAL_TEST_MODE__ */ int UTCTime_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { const UTCTime_t *st = (const UTCTime_t *)sptr; @@ -128,9 +128,9 @@ int UTCTime_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, return (cb("", 11, app_key) < 0) ? -1 : 0; ret = snprintf(buf, sizeof(buf), - "%04d-%02d-%02d %02d:%02d:%02d (GMT)", - tm.tm_year + 1900, tm.tm_mon + 1, tm.tm_mday, - tm.tm_hour, tm.tm_min, tm.tm_sec); + "%04d-%02d-%02d %02d:%02d:%02d (GMT)", + tm.tm_year + 1900, tm.tm_mon + 1, tm.tm_mday, + tm.tm_hour, tm.tm_min, tm.tm_sec); assert(ret > 0 && ret < (int)sizeof(buf)); return (cb(buf, ret, app_key) < 0) ? -1 : 0; } diff --git a/src/core/libs/supl/asn-supl/UTCTime.h b/src/core/libs/supl/asn-supl/UTCTime.h index be576d991..9411d4a0e 100644 --- a/src/core/libs/supl/asn-supl/UTCTime.h +++ b/src/core/libs/supl/asn-supl/UTCTime.h @@ -31,7 +31,7 @@ extern "C" /* See asn_time2GT() in GeneralizedTime.h */ UTCTime_t *asn_time2UT(UTCTime_t *__opt_ut, const struct tm * /*tm*/, - int force_gmt); + int force_gmt); #ifdef __cplusplus } diff --git a/src/core/libs/supl/asn-supl/UTRA-CarrierRSSI.c b/src/core/libs/supl/asn-supl/UTRA-CarrierRSSI.c index 1a55707bd..2e4742954 100644 --- a/src/core/libs/supl/asn-supl/UTRA-CarrierRSSI.c +++ b/src/core/libs/supl/asn-supl/UTRA-CarrierRSSI.c @@ -7,15 +7,15 @@ #include "UTRA-CarrierRSSI.h" int UTRA_CarrierRSSI_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,7 +29,7 @@ int UTRA_CarrierRSSI_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -57,76 +57,76 @@ static void UTRA_CarrierRSSI_1_inherit_TYPE_descriptor( } void UTRA_CarrierRSSI_free(asn_TYPE_descriptor_t *td, void *struct_ptr, - int contents_only) + int contents_only) { UTRA_CarrierRSSI_1_inherit_TYPE_descriptor(td); td->free_struct(td, struct_ptr, contents_only); } int UTRA_CarrierRSSI_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, - int ilevel, asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, asn_app_consume_bytes_f *cb, + void *app_key) { UTRA_CarrierRSSI_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t UTRA_CarrierRSSI_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, const void *bufptr, - size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, + void **structure, const void *bufptr, + size_t size, int tag_mode) { UTRA_CarrierRSSI_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t UTRA_CarrierRSSI_encode_der(asn_TYPE_descriptor_t *td, - void *structure, int tag_mode, - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int tag_mode, + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { UTRA_CarrierRSSI_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t UTRA_CarrierRSSI_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - void **structure, - const char *opt_mname, - const void *bufptr, size_t size) + asn_TYPE_descriptor_t *td, + void **structure, + const char *opt_mname, + const void *bufptr, size_t size) { UTRA_CarrierRSSI_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t UTRA_CarrierRSSI_encode_xer(asn_TYPE_descriptor_t *td, - void *structure, int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + void *structure, int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { UTRA_CarrierRSSI_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t UTRA_CarrierRSSI_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, - asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, + asn_per_data_t *per_data) { UTRA_CarrierRSSI_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t UTRA_CarrierRSSI_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, - asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, + asn_per_outp_t *per_out) { UTRA_CarrierRSSI_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); diff --git a/src/core/libs/supl/asn-supl/UlpMessage.c b/src/core/libs/supl/asn-supl/UlpMessage.c index 24940238c..ab9595406 100644 --- a/src/core/libs/supl/asn-supl/UlpMessage.c +++ b/src/core/libs/supl/asn-supl/UlpMessage.c @@ -14,47 +14,47 @@ static asn_per_constraints_t ASN_PER_TYPE_ULP_MESSAGE_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_UlpMessage_1[] = { {ATF_NOFLAGS, 0, offsetof(struct UlpMessage, choice.msSUPLINIT), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SUPLINIT, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "msSUPLINIT"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SUPLINIT, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "msSUPLINIT"}, {ATF_NOFLAGS, 0, offsetof(struct UlpMessage, choice.msSUPLSTART), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SUPLSTART, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "msSUPLSTART"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SUPLSTART, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "msSUPLSTART"}, {ATF_NOFLAGS, 0, offsetof(struct UlpMessage, choice.msSUPLRESPONSE), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SUPLRESPONSE, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "msSUPLRESPONSE"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SUPLRESPONSE, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "msSUPLRESPONSE"}, {ATF_NOFLAGS, 0, offsetof(struct UlpMessage, choice.msSUPLPOSINIT), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SUPLPOSINIT, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "msSUPLPOSINIT"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SUPLPOSINIT, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "msSUPLPOSINIT"}, {ATF_NOFLAGS, 0, offsetof(struct UlpMessage, choice.msSUPLPOS), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SUPLPOS, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "msSUPLPOS"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SUPLPOS, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "msSUPLPOS"}, {ATF_NOFLAGS, 0, offsetof(struct UlpMessage, choice.msSUPLEND), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SUPLEND, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "msSUPLEND"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SUPLEND, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "msSUPLEND"}, {ATF_NOFLAGS, 0, offsetof(struct UlpMessage, choice.msDUMMY2), - (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_DUMMY, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "msDUMMY2"}, + (ASN_TAG_CLASS_CONTEXT | (6 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_DUMMY, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "msDUMMY2"}, {ATF_NOFLAGS, 0, offsetof(struct UlpMessage, choice.msDUMMY3), - (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_DUMMY, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "msDUMMY3"}, + (ASN_TAG_CLASS_CONTEXT | (7 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_DUMMY, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "msDUMMY3"}, }; static asn_TYPE_tag2member_t asn_MAP_UlpMessage_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* msSUPLINIT at 37 */ diff --git a/src/core/libs/supl/asn-supl/UlpMessage.h b/src/core/libs/supl/asn-supl/UlpMessage.h index 901801104..dbc79a559 100644 --- a/src/core/libs/supl/asn-supl/UlpMessage.h +++ b/src/core/libs/supl/asn-supl/UlpMessage.h @@ -10,13 +10,13 @@ #include /* Including external dependencies */ -#include "SUPLINIT.h" -#include "SUPLSTART.h" -#include "SUPLRESPONSE.h" -#include "SUPLPOSINIT.h" -#include "SUPLPOS.h" -#include "SUPLEND.h" #include "DUMMY.h" +#include "SUPLEND.h" +#include "SUPLINIT.h" +#include "SUPLPOS.h" +#include "SUPLPOSINIT.h" +#include "SUPLRESPONSE.h" +#include "SUPLSTART.h" #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-supl/Velocity.c b/src/core/libs/supl/asn-supl/Velocity.c index c36506b26..f42ddf6cd 100644 --- a/src/core/libs/supl/asn-supl/Velocity.c +++ b/src/core/libs/supl/asn-supl/Velocity.c @@ -14,28 +14,28 @@ static asn_per_constraints_t ASN_PER_TYPE_VELOCITY_CONSTR_1 = { }; static asn_TYPE_member_t asn_MBR_Velocity_1[] = { {ATF_NOFLAGS, 0, offsetof(struct Velocity, choice.horvel), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Horvel, 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "horvel"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Horvel, 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "horvel"}, {ATF_NOFLAGS, 0, offsetof(struct Velocity, choice.horandvervel), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Horandvervel, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "horandvervel"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Horandvervel, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "horandvervel"}, {ATF_NOFLAGS, 0, offsetof(struct Velocity, choice.horveluncert), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Horveluncert, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "horveluncert"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Horveluncert, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "horveluncert"}, {ATF_NOFLAGS, 0, offsetof(struct Velocity, choice.horandveruncert), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_Horandveruncert, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "horandveruncert"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_Horandveruncert, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "horandveruncert"}, }; static asn_TYPE_tag2member_t asn_MAP_Velocity_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0}, /* horvel at 226 */ diff --git a/src/core/libs/supl/asn-supl/Velocity.h b/src/core/libs/supl/asn-supl/Velocity.h index d0cf33508..17cdd47ff 100644 --- a/src/core/libs/supl/asn-supl/Velocity.h +++ b/src/core/libs/supl/asn-supl/Velocity.h @@ -10,10 +10,10 @@ #include /* Including external dependencies */ -#include "Horvel.h" -#include "Horandvervel.h" -#include "Horveluncert.h" #include "Horandveruncert.h" +#include "Horandvervel.h" +#include "Horvel.h" +#include "Horveluncert.h" #include #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-supl/Ver.c b/src/core/libs/supl/asn-supl/Ver.c index 3eab8557b..f11e53b72 100644 --- a/src/core/libs/supl/asn-supl/Ver.c +++ b/src/core/libs/supl/asn-supl/Ver.c @@ -7,7 +7,7 @@ #include "Ver.h" int Ver_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { const BIT_STRING_t *st = (const BIT_STRING_t *)sptr; size_t size; @@ -15,7 +15,7 @@ int Ver_constraint(asn_TYPE_descriptor_t *td, const void *sptr, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -37,7 +37,7 @@ int Ver_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -70,60 +70,60 @@ void Ver_free(asn_TYPE_descriptor_t *td, void *struct_ptr, int contents_only) } int Ver_print(asn_TYPE_descriptor_t *td, const void *struct_ptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { Ver_1_inherit_TYPE_descriptor(td); return td->print_struct(td, struct_ptr, ilevel, cb, app_key); } asn_dec_rval_t Ver_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const void *bufptr, size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, void **structure, + const void *bufptr, size_t size, int tag_mode) { Ver_1_inherit_TYPE_descriptor(td); return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, - tag_mode); + tag_mode); } asn_enc_rval_t Ver_encode_der(asn_TYPE_descriptor_t *td, void *structure, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { Ver_1_inherit_TYPE_descriptor(td); return td->der_encoder(td, structure, tag_mode, tag, cb, app_key); } asn_dec_rval_t Ver_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **structure, - const char *opt_mname, const void *bufptr, - size_t size) + asn_TYPE_descriptor_t *td, void **structure, + const char *opt_mname, const void *bufptr, + size_t size) { Ver_1_inherit_TYPE_descriptor(td); return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, - size); + size); } asn_enc_rval_t Ver_encode_xer(asn_TYPE_descriptor_t *td, void *structure, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { Ver_1_inherit_TYPE_descriptor(td); return td->xer_encoder(td, structure, ilevel, flags, cb, app_key); } asn_dec_rval_t Ver_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **structure, asn_per_data_t *per_data) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **structure, asn_per_data_t *per_data) { Ver_1_inherit_TYPE_descriptor(td); return td->uper_decoder(opt_codec_ctx, td, constraints, structure, - per_data); + per_data); } asn_enc_rval_t Ver_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *structure, asn_per_outp_t *per_out) + asn_per_constraints_t *constraints, + void *structure, asn_per_outp_t *per_out) { Ver_1_inherit_TYPE_descriptor(td); return td->uper_encoder(td, constraints, structure, per_out); @@ -152,7 +152,7 @@ asn_TYPE_descriptor_t asn_DEF_Ver = { 0, /* Use generic outmost tag fetcher */ asn_DEF_Ver_tags_1, sizeof(asn_DEF_Ver_tags_1) / sizeof(asn_DEF_Ver_tags_1[0]), /* 1 */ - asn_DEF_Ver_tags_1, /* Same as above */ + asn_DEF_Ver_tags_1, /* Same as above */ sizeof(asn_DEF_Ver_tags_1) / sizeof(asn_DEF_Ver_tags_1[0]), /* 1 */ &ASN_PER_TYPE_VER_CONSTR_1, 0, diff --git a/src/core/libs/supl/asn-supl/Version.c b/src/core/libs/supl/asn-supl/Version.c index 68e337180..2f1d951db 100644 --- a/src/core/libs/supl/asn-supl/Version.c +++ b/src/core/libs/supl/asn-supl/Version.c @@ -7,15 +7,15 @@ #include "Version.h" static int memb_maj_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,21 +29,21 @@ static int memb_maj_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_min_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -57,22 +57,22 @@ static int memb_min_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_servind_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -86,7 +86,7 @@ static int memb_servind_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -111,17 +111,17 @@ static asn_per_constraints_t ASN_PER_MEMB_SERVIND_CONSTR_4 = { }; static asn_TYPE_member_t asn_MBR_Version_1[] = { {ATF_NOFLAGS, 0, offsetof(struct Version, maj), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_maj_constraint_1, &ASN_PER_MEMB_MAJ_CONSTR_2, - 0, "maj"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_maj_constraint_1, &ASN_PER_MEMB_MAJ_CONSTR_2, + 0, "maj"}, {ATF_NOFLAGS, 0, offsetof(struct Version, min), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_min_constraint_1, &ASN_PER_MEMB_MIN_CONSTR_3, - 0, "min"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_min_constraint_1, &ASN_PER_MEMB_MIN_CONSTR_3, + 0, "min"}, {ATF_NOFLAGS, 0, offsetof(struct Version, servind), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_servind_constraint_1, - &ASN_PER_MEMB_SERVIND_CONSTR_4, 0, "servind"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_servind_constraint_1, + &ASN_PER_MEMB_SERVIND_CONSTR_4, 0, "servind"}, }; static ber_tlv_tag_t asn_DEF_Version_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))}; @@ -156,9 +156,9 @@ asn_TYPE_descriptor_t asn_DEF_Version = { 0, /* Use generic outmost tag fetcher */ asn_DEF_Version_tags_1, sizeof(asn_DEF_Version_tags_1) / sizeof(asn_DEF_Version_tags_1[0]), /* 1 */ - asn_DEF_Version_tags_1, /* Same as above */ + asn_DEF_Version_tags_1, /* Same as above */ sizeof(asn_DEF_Version_tags_1) / sizeof(asn_DEF_Version_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_Version_1, 3, /* Elements count */ &asn_SPC_Version_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-supl/VisibleString.c b/src/core/libs/supl/asn-supl/VisibleString.c index f4382431b..c500a791f 100644 --- a/src/core/libs/supl/asn-supl/VisibleString.c +++ b/src/core/libs/supl/asn-supl/VisibleString.c @@ -2,8 +2,8 @@ * Copyright (c) 2003, 2006 Lev Walkin . All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ -#include #include +#include /* * VisibleString basic type description. @@ -42,8 +42,8 @@ asn_TYPE_descriptor_t asn_DEF_VisibleString = { }; int VisibleString_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { const VisibleString_t *st = (const VisibleString_t *)sptr; @@ -63,10 +63,10 @@ int VisibleString_constraint(asn_TYPE_descriptor_t *td, const void *sptr, if (*buf < 0x20 || *buf > 0x7e) { _ASN_CTFAIL(app_key, td, sptr, - "%s: value byte %ld (%d) " - "not in VisibleString alphabet (%s:%d)", - td->name, ((buf - st->buf) + 1), *buf, - __FILE__, __LINE__); + "%s: value byte %ld (%d) " + "not in VisibleString alphabet (%s:%d)", + td->name, ((buf - st->buf) + 1), *buf, + __FILE__, __LINE__); return -1; } } @@ -74,7 +74,7 @@ int VisibleString_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } diff --git a/src/core/libs/supl/asn-supl/WcdmaCellInformation.c b/src/core/libs/supl/asn-supl/WcdmaCellInformation.c index dafa0a0ce..4acd4bfad 100644 --- a/src/core/libs/supl/asn-supl/WcdmaCellInformation.c +++ b/src/core/libs/supl/asn-supl/WcdmaCellInformation.c @@ -7,15 +7,15 @@ #include "WcdmaCellInformation.h" static int memb_refMCC_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -29,21 +29,21 @@ static int memb_refMCC_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_refMNC_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -57,21 +57,21 @@ static int memb_refMNC_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_refUC_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -85,7 +85,7 @@ static int memb_refUC_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -99,7 +99,7 @@ static int memb_primaryScramblingCode_constraint_1( if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -113,7 +113,7 @@ static int memb_primaryScramblingCode_constraint_1( else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -144,35 +144,35 @@ static asn_per_constraints_t ASN_PER_MEMB_PRIMARY_SCRAMBLING_CODE_CONSTR_6 = { }; static asn_TYPE_member_t asn_MBR_WcdmaCellInformation_1[] = { {ATF_NOFLAGS, 0, offsetof(struct WcdmaCellInformation, refMCC), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_refMCC_constraint_1, - &ASN_PER_MEMB_REF_MCC_CONSTR_2, 0, "refMCC"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_refMCC_constraint_1, + &ASN_PER_MEMB_REF_MCC_CONSTR_2, 0, "refMCC"}, {ATF_NOFLAGS, 0, offsetof(struct WcdmaCellInformation, refMNC), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_refMNC_constraint_1, - &ASN_PER_MEMB_REF_MNC_CONSTR_3, 0, "refMNC"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_refMNC_constraint_1, + &ASN_PER_MEMB_REF_MNC_CONSTR_3, 0, "refMNC"}, {ATF_NOFLAGS, 0, offsetof(struct WcdmaCellInformation, refUC), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_refUC_constraint_1, - &ASN_PER_MEMB_REF_UC_CONSTR_4, 0, "refUC"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_refUC_constraint_1, + &ASN_PER_MEMB_REF_UC_CONSTR_4, 0, "refUC"}, {ATF_POINTER, 3, offsetof(struct WcdmaCellInformation, frequencyInfo), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_FrequencyInfo, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "frequencyInfo"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_FrequencyInfo, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "frequencyInfo"}, {ATF_POINTER, 2, - offsetof(struct WcdmaCellInformation, primaryScramblingCode), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_primaryScramblingCode_constraint_1, - &ASN_PER_MEMB_PRIMARY_SCRAMBLING_CODE_CONSTR_6, 0, - "primaryScramblingCode"}, + offsetof(struct WcdmaCellInformation, primaryScramblingCode), + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_primaryScramblingCode_constraint_1, + &ASN_PER_MEMB_PRIMARY_SCRAMBLING_CODE_CONSTR_6, 0, + "primaryScramblingCode"}, {ATF_POINTER, 1, offsetof(struct WcdmaCellInformation, measuredResultsList), - (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_MeasuredResultsList, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "measuredResultsList"}, + (ASN_TAG_CLASS_CONTEXT | (5 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_MeasuredResultsList, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "measuredResultsList"}, }; static int asn_MAP_WcdmaCellInformation_oms_1[] = {3, 4, 5}; static ber_tlv_tag_t asn_DEF_WcdmaCellInformation_tags_1[] = { @@ -183,9 +183,9 @@ static asn_TYPE_tag2member_t asn_MAP_WcdmaCellInformation_tag2el_1[] = { {(ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0}, /* refUC at 114 */ {(ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, 0}, /* frequencyInfo at 115 */ {(ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, - 0}, /* primaryScramblingCode at 116 */ + 0}, /* primaryScramblingCode at 116 */ {(ASN_TAG_CLASS_CONTEXT | (5 << 2)), 5, 0, - 0} /* measuredResultsList at 117 */ + 0} /* measuredResultsList at 117 */ }; static asn_SEQUENCE_specifics_t asn_SPC_WcdmaCellInformation_specs_1 = { sizeof(struct WcdmaCellInformation), @@ -217,7 +217,7 @@ asn_TYPE_descriptor_t asn_DEF_WcdmaCellInformation = { asn_DEF_WcdmaCellInformation_tags_1, /* Same as above */ sizeof(asn_DEF_WcdmaCellInformation_tags_1) / sizeof(asn_DEF_WcdmaCellInformation_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_WcdmaCellInformation_1, 6, /* Elements count */ &asn_SPC_WcdmaCellInformation_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-supl/XNavigationModel.c b/src/core/libs/supl/asn-supl/XNavigationModel.c index 3f9dd7164..9f3f84c48 100644 --- a/src/core/libs/supl/asn-supl/XNavigationModel.c +++ b/src/core/libs/supl/asn-supl/XNavigationModel.c @@ -7,16 +7,16 @@ #include "XNavigationModel.h" static int memb_gpsWeek_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -30,21 +30,21 @@ static int memb_gpsWeek_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_gpsToe_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -58,21 +58,21 @@ static int memb_gpsToe_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_nSAT_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -86,22 +86,22 @@ static int memb_nSAT_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } static int memb_toeLimit_constraint_1(asn_TYPE_descriptor_t *td, - const void *sptr, - asn_app_constraint_failed_f *ctfailcb, - void *app_key) + const void *sptr, + asn_app_constraint_failed_f *ctfailcb, + void *app_key) { long value; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -115,7 +115,7 @@ static int memb_toeLimit_constraint_1(asn_TYPE_descriptor_t *td, else { _ASN_CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } } @@ -146,27 +146,27 @@ static asn_per_constraints_t ASN_PER_MEMB_TOE_LIMIT_CONSTR_5 = { }; static asn_TYPE_member_t asn_MBR_XNavigationModel_1[] = { {ATF_NOFLAGS, 0, offsetof(struct XNavigationModel, gpsWeek), - (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_gpsWeek_constraint_1, - &ASN_PER_MEMB_GPS_WEEK_CONSTR_2, 0, "gpsWeek"}, + (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_gpsWeek_constraint_1, + &ASN_PER_MEMB_GPS_WEEK_CONSTR_2, 0, "gpsWeek"}, {ATF_NOFLAGS, 0, offsetof(struct XNavigationModel, gpsToe), - (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_gpsToe_constraint_1, - &ASN_PER_MEMB_GPS_TOE_CONSTR_3, 0, "gpsToe"}, + (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_gpsToe_constraint_1, + &ASN_PER_MEMB_GPS_TOE_CONSTR_3, 0, "gpsToe"}, {ATF_NOFLAGS, 0, offsetof(struct XNavigationModel, nSAT), - (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_nSAT_constraint_1, - &ASN_PER_MEMB_N_SAT_CONSTR_4, 0, "nSAT"}, + (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_nSAT_constraint_1, + &ASN_PER_MEMB_N_SAT_CONSTR_4, 0, "nSAT"}, {ATF_NOFLAGS, 0, offsetof(struct XNavigationModel, toeLimit), - (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_NativeInteger, memb_toeLimit_constraint_1, - &ASN_PER_MEMB_TOE_LIMIT_CONSTR_5, 0, "toeLimit"}, + (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_NativeInteger, memb_toeLimit_constraint_1, + &ASN_PER_MEMB_TOE_LIMIT_CONSTR_5, 0, "toeLimit"}, {ATF_POINTER, 1, offsetof(struct XNavigationModel, satInfo), - (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ - &asn_DEF_SatelliteInfo, - 0, /* Defer constraints checking to the member type */ - 0, /* No PER visible constraints */ - 0, "satInfo"}, + (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ + &asn_DEF_SatelliteInfo, + 0, /* Defer constraints checking to the member type */ + 0, /* No PER visible constraints */ + 0, "satInfo"}, }; static int asn_MAP_XNavigationModel_oms_1[] = {4}; static ber_tlv_tag_t asn_DEF_XNavigationModel_tags_1[] = { @@ -208,7 +208,7 @@ asn_TYPE_descriptor_t asn_DEF_XNavigationModel = { asn_DEF_XNavigationModel_tags_1, /* Same as above */ sizeof(asn_DEF_XNavigationModel_tags_1) / sizeof(asn_DEF_XNavigationModel_tags_1[0]), /* 1 */ - 0, /* No PER visible constraints */ + 0, /* No PER visible constraints */ asn_MBR_XNavigationModel_1, 5, /* Elements count */ &asn_SPC_XNavigationModel_specs_1 /* Additional specs */ diff --git a/src/core/libs/supl/asn-supl/asn_SEQUENCE_OF.c b/src/core/libs/supl/asn-supl/asn_SEQUENCE_OF.c index 924cb150e..67981e72f 100644 --- a/src/core/libs/supl/asn-supl/asn_SEQUENCE_OF.c +++ b/src/core/libs/supl/asn-supl/asn_SEQUENCE_OF.c @@ -2,8 +2,8 @@ * Copyright (c) 2003, 2004 Lev Walkin . All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ -#include #include +#include typedef A_SEQUENCE_OF(void) asn_sequence; diff --git a/src/core/libs/supl/asn-supl/asn_SET_OF.c b/src/core/libs/supl/asn-supl/asn_SET_OF.c index 2239dbe58..317ebea09 100644 --- a/src/core/libs/supl/asn-supl/asn_SET_OF.c +++ b/src/core/libs/supl/asn-supl/asn_SET_OF.c @@ -2,8 +2,8 @@ * Copyright (c) 2003, 2004 Lev Walkin . All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ -#include #include +#include #include /* diff --git a/src/core/libs/supl/asn-supl/asn_application.h b/src/core/libs/supl/asn-supl/asn_application.h index ec8567737..baf070e4a 100644 --- a/src/core/libs/supl/asn-supl/asn_application.h +++ b/src/core/libs/supl/asn-supl/asn_application.h @@ -8,8 +8,10 @@ #ifndef _ASN_APPLICATION_H_ #define _ASN_APPLICATION_H_ +// clang-format off #include "asn_system.h" /* for platform-dependent types */ #include "asn_codecs.h" /* for ASN.1 codecs specifics */ +// clang-format on #ifdef __cplusplus extern "C" @@ -24,7 +26,7 @@ extern "C" * Non-negative return values indicate success, and ignored. */ typedef int(asn_app_consume_bytes_f)(const void *buffer, size_t size, - void *application_specific_key); + void *application_specific_key); /* * A callback of this type is called whenever constraint validation fails diff --git a/src/core/libs/supl/asn-supl/asn_codecs_prim.c b/src/core/libs/supl/asn-supl/asn_codecs_prim.c index 692601c17..75b51ad38 100644 --- a/src/core/libs/supl/asn-supl/asn_codecs_prim.c +++ b/src/core/libs/supl/asn-supl/asn_codecs_prim.c @@ -2,17 +2,17 @@ * Copyright (c) 2003, 2004 Lev Walkin . All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ -#include #include +#include #include /* * Decode an always-primitive type. */ asn_dec_rval_t ber_decode_primitive(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **sptr, - const void *buf_ptr, size_t size, - int tag_mode) + asn_TYPE_descriptor_t *td, void **sptr, + const void *buf_ptr, size_t size, + int tag_mode) { ASN__PRIMITIVE_TYPE_t *st = (ASN__PRIMITIVE_TYPE_t *)*sptr; asn_dec_rval_t rval; @@ -34,7 +34,7 @@ asn_dec_rval_t ber_decode_primitive(asn_codec_ctx_t *opt_codec_ctx, * Check tags and extract value length. */ rval = ber_check_tags(opt_codec_ctx, td, 0, buf_ptr, size, tag_mode, 0, - &length, 0); + &length, 0); if (rval.code != RC_OK) return rval; ASN_DEBUG("%s length is %d bytes", td->name, (int)length); @@ -73,7 +73,7 @@ asn_dec_rval_t ber_decode_primitive(asn_codec_ctx_t *opt_codec_ctx, rval.consumed += length; ASN_DEBUG("Took %ld/%ld bytes to encode %s", (long)rval.consumed, - (long)length, td->name); + (long)length, td->name); return rval; } @@ -82,14 +82,14 @@ asn_dec_rval_t ber_decode_primitive(asn_codec_ctx_t *opt_codec_ctx, * Encode an always-primitive type using DER. */ asn_enc_rval_t der_encode_primitive(asn_TYPE_descriptor_t *td, void *sptr, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { asn_enc_rval_t erval; ASN__PRIMITIVE_TYPE_t *st = (ASN__PRIMITIVE_TYPE_t *)sptr; ASN_DEBUG("%s %s as a primitive type (tm=%d)", - cb ? "Encoding" : "Estimating", td->name, tag_mode); + cb ? "Encoding" : "Estimating", td->name, tag_mode); erval.encoded = der_write_tags(td, st->size, tag_mode, 0, tag, cb, app_key); ASN_DEBUG("%s wrote tags %d", td->name, (int)erval.encoded); @@ -120,7 +120,7 @@ asn_enc_rval_t der_encode_primitive(asn_TYPE_descriptor_t *td, void *sptr, } void ASN__PRIMITIVE_TYPE_free(asn_TYPE_descriptor_t *td, void *sptr, - int contents_only) + int contents_only) { ASN__PRIMITIVE_TYPE_t *st = (ASN__PRIMITIVE_TYPE_t *)sptr; @@ -146,7 +146,7 @@ struct xdp_arg_s }; static int xer_decode__unexpected_tag(void *key, const void *chunk_buf, - size_t chunk_size) + size_t chunk_size) { struct xdp_arg_s *arg = (struct xdp_arg_s *)key; enum xer_pbd_rval bret; @@ -162,26 +162,26 @@ static int xer_decode__unexpected_tag(void *key, const void *chunk_buf, } bret = arg->prim_body_decoder(arg->type_descriptor, arg->struct_key, - chunk_buf, chunk_size); + chunk_buf, chunk_size); switch (bret) { - case XPBD_SYSTEM_FAILURE: - case XPBD_DECODER_LIMIT: - case XPBD_BROKEN_ENCODING: - break; - case XPBD_BODY_CONSUMED: - /* Tag decoded successfully */ - arg->decoded_something = 1; - /* Fall through */ - case XPBD_NOT_BODY_IGNORE: /* Safe to proceed further */ - return 0; + case XPBD_SYSTEM_FAILURE: + case XPBD_DECODER_LIMIT: + case XPBD_BROKEN_ENCODING: + break; + case XPBD_BODY_CONSUMED: + /* Tag decoded successfully */ + arg->decoded_something = 1; + /* Fall through */ + case XPBD_NOT_BODY_IGNORE: /* Safe to proceed further */ + return 0; } return -1; } static ssize_t xer_decode__body(void *key, const void *chunk_buf, - size_t chunk_size, int have_more) + size_t chunk_size, int have_more) { struct xdp_arg_s *arg = (struct xdp_arg_s *)key; enum xer_pbd_rval bret; @@ -210,19 +210,19 @@ static ssize_t xer_decode__body(void *key, const void *chunk_buf, } bret = arg->prim_body_decoder(arg->type_descriptor, arg->struct_key, - chunk_buf, chunk_size); + chunk_buf, chunk_size); switch (bret) { - case XPBD_SYSTEM_FAILURE: - case XPBD_DECODER_LIMIT: - case XPBD_BROKEN_ENCODING: - break; - case XPBD_BODY_CONSUMED: - /* Tag decoded successfully */ - arg->decoded_something = 1; - /* Fall through */ - case XPBD_NOT_BODY_IGNORE: /* Safe to proceed further */ - return chunk_size; + case XPBD_SYSTEM_FAILURE: + case XPBD_DECODER_LIMIT: + case XPBD_BROKEN_ENCODING: + break; + case XPBD_BODY_CONSUMED: + /* Tag decoded successfully */ + arg->decoded_something = 1; + /* Fall through */ + case XPBD_NOT_BODY_IGNORE: /* Safe to proceed further */ + return chunk_size; } return -1; @@ -255,46 +255,46 @@ asn_dec_rval_t xer_decode_primitive( s_arg.want_more = 0; rc = xer_decode_general(opt_codec_ctx, &s_ctx, &s_arg, xml_tag, buf_ptr, - size, xer_decode__unexpected_tag, xer_decode__body); + size, xer_decode__unexpected_tag, xer_decode__body); switch (rc.code) { - case RC_OK: - if (!s_arg.decoded_something) - { - char ch; - ASN_DEBUG( - "Primitive body is not recognized, " - "supplying empty one"); - /* + case RC_OK: + if (!s_arg.decoded_something) + { + char ch; + ASN_DEBUG( + "Primitive body is not recognized, " + "supplying empty one"); + /* * Decoding opportunity has come and gone. * Where's the result? * Try to feed with empty body, see if it eats it. */ - if (prim_body_decoder(s_arg.type_descriptor, - s_arg.struct_key, &ch, - 0) != XPBD_BODY_CONSUMED) - { - /* + if (prim_body_decoder(s_arg.type_descriptor, + s_arg.struct_key, &ch, + 0) != XPBD_BODY_CONSUMED) + { + /* * This decoder does not like empty stuff. */ - _ASN_DECODE_FAILED; - } - } - break; - case RC_WMORE: - /* + _ASN_DECODE_FAILED; + } + } + break; + case RC_WMORE: + /* * Redo the whole thing later. * We don't have a context to save intermediate parsing state. */ - rc.consumed = 0; - break; - case RC_FAIL: - rc.consumed = 0; - if (s_arg.want_more) - rc.code = RC_WMORE; - else - _ASN_DECODE_FAILED; - break; + rc.consumed = 0; + break; + case RC_FAIL: + rc.consumed = 0; + if (s_arg.want_more) + rc.code = RC_WMORE; + else + _ASN_DECODE_FAILED; + break; } return rc; } diff --git a/src/core/libs/supl/asn-supl/asn_codecs_prim.h b/src/core/libs/supl/asn-supl/asn_codecs_prim.h index 275fbbdbb..b7226cf43 100644 --- a/src/core/libs/supl/asn-supl/asn_codecs_prim.h +++ b/src/core/libs/supl/asn-supl/asn_codecs_prim.h @@ -14,8 +14,8 @@ extern "C" typedef struct ASN__PRIMITIVE_TYPE_s { - uint8_t *buf; /* Buffer with consecutive primitive encoding bytes */ - int size; /* Size of the buffer */ + uint8_t *buf; /* Buffer with consecutive primitive encoding bytes */ + int size; /* Size of the buffer */ } ASN__PRIMITIVE_TYPE_t; /* Do not use this type directly! */ asn_struct_free_f ASN__PRIMITIVE_TYPE_free; diff --git a/src/core/libs/supl/asn-supl/asn_internal.h b/src/core/libs/supl/asn-supl/asn_internal.h index 339dc86e4..2e0a994b4 100644 --- a/src/core/libs/supl/asn-supl/asn_internal.h +++ b/src/core/libs/supl/asn-supl/asn_internal.h @@ -55,7 +55,10 @@ extern "C" #define ASN_DEBUG ASN_DEBUG_f #endif /* __GNUC__ */ #else /* EMIT_ASN_DEBUG != 1 */ - static inline void ASN_DEBUG(const char *fmt, ...) { (void)fmt; } + static inline void ASN_DEBUG(const char *fmt, ...) + { + (void)fmt; + } #endif /* EMIT_ASN_DEBUG */ #endif /* ASN_DEBUG */ @@ -115,7 +118,7 @@ extern "C" if (usedstack < -(ptrdiff_t)ctx->max_stack_size) { ASN_DEBUG("Stack limit %ld reached", - (long)ctx->max_stack_size); + (long)ctx->max_stack_size); return -1; } } diff --git a/src/core/libs/supl/asn-supl/asn_system.h b/src/core/libs/supl/asn-supl/asn_system.h index 5eacc2ecb..1fa6461f9 100644 --- a/src/core/libs/supl/asn-supl/asn_system.h +++ b/src/core/libs/supl/asn-supl/asn_system.h @@ -13,13 +13,13 @@ #include "config.h" #endif +#include /* For LONG_MAX */ +#include /* For va_start */ +#include /* for offsetof and ptrdiff_t */ #include /* For snprintf(3) */ #include /* For *alloc(3) */ #include /* For memcpy(3) */ #include /* For size_t */ -#include /* For LONG_MAX */ -#include /* For va_start */ -#include /* for offsetof and ptrdiff_t */ #ifdef WIN32 @@ -30,7 +30,7 @@ /* To avoid linking with ws2_32.lib, here's the definition of ntohl() */ #define sys_ntohl(l) \ ((((l) << 24) & 0xff000000) | (((l) << 16) & 0xff0000) | \ - (((l) << 8) & 0xff00) | ((l)&0xff)) + (((l) << 8) & 0xff00) | ((l)&0xff)) #ifdef _MSC_VER /* MSVS.Net */ #ifndef __cplusplus @@ -46,8 +46,8 @@ typedef unsigned short uint16_t; typedef unsigned int uint32_t; #endif /* ASSUMESTDTYPES */ #define WIN32_LEAN_AND_MEAN -#include #include +#include #define isnan _isnan #define finite _finite #define copysign _copysign diff --git a/src/core/libs/supl/asn-supl/ber_decoder.c b/src/core/libs/supl/asn-supl/ber_decoder.c index 36fc4b9d2..c2dbabbfe 100644 --- a/src/core/libs/supl/asn-supl/ber_decoder.c +++ b/src/core/libs/supl/asn-supl/ber_decoder.c @@ -33,8 +33,8 @@ * The BER decoder of any type. */ asn_dec_rval_t ber_decode(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *type_descriptor, - void **struct_ptr, const void *ptr, size_t size) + asn_TYPE_descriptor_t *type_descriptor, + void **struct_ptr, const void *ptr, size_t size) { asn_codec_ctx_t s_codec_ctx; @@ -73,10 +73,10 @@ asn_dec_rval_t ber_decode(asn_codec_ctx_t *opt_codec_ctx, * Check the set of >> tags matches the definition. */ asn_dec_rval_t ber_check_tags(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_struct_ctx_t *opt_ctx, const void *ptr, - size_t size, int tag_mode, int last_tag_form, - ber_tlv_len_t *last_length, int *opt_tlv_form) + asn_TYPE_descriptor_t *td, + asn_struct_ctx_t *opt_ctx, const void *ptr, + size_t size, int tag_mode, int last_tag_form, + ber_tlv_len_t *last_length, int *opt_tlv_form) { ssize_t consumed_myself = 0; ssize_t tag_len; @@ -85,7 +85,7 @@ asn_dec_rval_t ber_check_tags(asn_codec_ctx_t *opt_codec_ctx, ber_tlv_len_t tlv_len; ber_tlv_len_t limit_len = -1; int expect_00_terminators = 0; - int tlv_constr = -1; /* If CHOICE, opt_tlv_form is not given */ + int tlv_constr = -1; /* If CHOICE, opt_tlv_form is not given */ int step = opt_ctx ? opt_ctx->step : 0; /* Where we left previously */ int tagno; @@ -119,7 +119,7 @@ asn_dec_rval_t ber_check_tags(asn_codec_ctx_t *opt_codec_ctx, tagno = step /* Continuing where left previously */ + (tag_mode == 1 ? -1 : 0); ASN_DEBUG("ber_check_tags(%s, size=%ld, tm=%d, step=%d, tagno=%d)", - td->name, (long)size, tag_mode, step, tagno); + td->name, (long)size, tag_mode, step, tagno); /* assert(td->tags_count >= 1) May not be the case for CHOICE or ANY */ if (tag_mode == 0 && tagno == td->tags_count) @@ -132,20 +132,20 @@ asn_dec_rval_t ber_check_tags(asn_codec_ctx_t *opt_codec_ctx, tag_len = ber_fetch_tag(ptr, size, &tlv_tag); switch (tag_len) { - case -1: - RETURN(RC_FAIL); - case 0: - RETURN(RC_WMORE); + case -1: + RETURN(RC_FAIL); + case 0: + RETURN(RC_WMORE); } tlv_constr = BER_TLV_CONSTRUCTED(ptr); len_len = ber_fetch_length(tlv_constr, (const char *)ptr + tag_len, - size - tag_len, &tlv_len); + size - tag_len, &tlv_len); switch (len_len) { - case -1: - RETURN(RC_FAIL); - case 0: - RETURN(RC_WMORE); + case -1: + RETURN(RC_FAIL); + case 0: + RETURN(RC_WMORE); } ASN_DEBUG("Advancing %ld in ANY case", (tag_len + len_len)); ADVANCE(tag_len + len_len); @@ -167,10 +167,10 @@ asn_dec_rval_t ber_check_tags(asn_codec_ctx_t *opt_codec_ctx, ber_tlv_tag_string(tlv_tag)); switch (tag_len) { - case -1: - RETURN(RC_FAIL); - case 0: - RETURN(RC_WMORE); + case -1: + RETURN(RC_FAIL); + case 0: + RETURN(RC_WMORE); } tlv_constr = BER_TLV_CONSTRUCTED(ptr); @@ -224,7 +224,7 @@ asn_dec_rval_t ber_check_tags(asn_codec_ctx_t *opt_codec_ctx, if (last_tag_form != tlv_constr && last_tag_form != -1) { ASN_DEBUG("last_tag_form %d != %d", last_tag_form, - tlv_constr); + tlv_constr); RETURN(RC_FAIL); } } @@ -233,14 +233,14 @@ asn_dec_rval_t ber_check_tags(asn_codec_ctx_t *opt_codec_ctx, * Fetch and process L from TLV. */ len_len = ber_fetch_length(tlv_constr, (const char *)ptr + tag_len, - size - tag_len, &tlv_len); + size - tag_len, &tlv_len); ASN_DEBUG("Fetchinig len = %ld", (long)len_len); switch (len_len) { - case -1: - RETURN(RC_FAIL); - case 0: - RETURN(RC_WMORE); + case -1: + RETURN(RC_FAIL); + case 0: + RETURN(RC_WMORE); } /* @@ -300,7 +300,7 @@ asn_dec_rval_t ber_check_tags(asn_codec_ctx_t *opt_codec_ctx, * with the outer TLV's length value. */ ASN_DEBUG("Outer TLV is %ld and inner is %ld", - (long)limit_len, (long)tlv_len); + (long)limit_len, (long)tlv_len); RETURN(RC_FAIL); } diff --git a/src/core/libs/supl/asn-supl/ber_decoder.h b/src/core/libs/supl/asn-supl/ber_decoder.h index b142a9eed..7b9fa3d0e 100644 --- a/src/core/libs/supl/asn-supl/ber_decoder.h +++ b/src/core/libs/supl/asn-supl/ber_decoder.h @@ -53,8 +53,8 @@ extern "C" struct asn_TYPE_descriptor_s *td, asn_struct_ctx_t *opt_ctx, /* saved decoding context */ const void *ptr, size_t size, - int tag_mode, /* {-1,0,1}: IMPLICIT, no, EXPLICIT */ - int last_tag_form, /* {-1,0:1}: any, primitive, constr */ + int tag_mode, /* {-1,0,1}: IMPLICIT, no, EXPLICIT */ + int last_tag_form, /* {-1,0:1}: any, primitive, constr */ ber_tlv_len_t *last_length, int *opt_tlv_form /* optional tag form */ ); diff --git a/src/core/libs/supl/asn-supl/ber_tlv_length.c b/src/core/libs/supl/asn-supl/ber_tlv_length.c index 9d6e2998d..4efe95b95 100644 --- a/src/core/libs/supl/asn-supl/ber_tlv_length.c +++ b/src/core/libs/supl/asn-supl/ber_tlv_length.c @@ -7,7 +7,7 @@ #include ssize_t ber_fetch_length(int _is_constructed, const void *bufptr, size_t size, - ber_tlv_len_t *len_r) + ber_tlv_len_t *len_r) { const uint8_t *buf = (const uint8_t *)bufptr; unsigned oct; @@ -80,7 +80,7 @@ ssize_t ber_fetch_length(int _is_constructed, const void *bufptr, size_t size, } ssize_t ber_skip_length(asn_codec_ctx_t *opt_codec_ctx, int _is_constructed, - const void *ptr, size_t size) + const void *ptr, size_t size) { ber_tlv_len_t vlen; /* Length of V in TLV */ ssize_t tl; /* Length of L in TLV */ @@ -121,7 +121,7 @@ ssize_t ber_skip_length(asn_codec_ctx_t *opt_codec_ctx, int _is_constructed, if (tl <= 0) return tl; ll = ber_skip_length(opt_codec_ctx, BER_TLV_CONSTRUCTED(ptr), - ((const char *)ptr) + tl, size - tl); + ((const char *)ptr) + tl, size - tl); if (ll <= 0) return ll; skip += tl + ll; diff --git a/src/core/libs/supl/asn-supl/ber_tlv_length.h b/src/core/libs/supl/asn-supl/ber_tlv_length.h index 9daae27af..211855c29 100644 --- a/src/core/libs/supl/asn-supl/ber_tlv_length.h +++ b/src/core/libs/supl/asn-supl/ber_tlv_length.h @@ -23,7 +23,7 @@ extern "C" * that the value is of indefinite length. */ ssize_t ber_fetch_length(int _is_constructed, const void *bufptr, - size_t size, ber_tlv_len_t *len_r); + size_t size, ber_tlv_len_t *len_r); /* * This function expects bufptr to be positioned over L in TLV. @@ -43,7 +43,7 @@ extern "C" * against the supplied buffer's size. */ size_t der_tlv_length_serialize(ber_tlv_len_t len, void *bufptr, - size_t size); + size_t size); #ifdef __cplusplus } diff --git a/src/core/libs/supl/asn-supl/ber_tlv_tag.c b/src/core/libs/supl/asn-supl/ber_tlv_tag.c index 2de303992..0bef65296 100644 --- a/src/core/libs/supl/asn-supl/ber_tlv_tag.c +++ b/src/core/libs/supl/asn-supl/ber_tlv_tag.c @@ -83,18 +83,18 @@ ssize_t ber_tlv_tag_snprint(ber_tlv_tag_t tag, char *buf, size_t size) switch (tag & 0x3) { - case ASN_TAG_CLASS_UNIVERSAL: - type = "UNIVERSAL "; - break; - case ASN_TAG_CLASS_APPLICATION: - type = "APPLICATION "; - break; - case ASN_TAG_CLASS_CONTEXT: - type = ""; - break; - case ASN_TAG_CLASS_PRIVATE: - type = "PRIVATE "; - break; + case ASN_TAG_CLASS_UNIVERSAL: + type = "UNIVERSAL "; + break; + case ASN_TAG_CLASS_APPLICATION: + type = "APPLICATION "; + break; + case ASN_TAG_CLASS_CONTEXT: + type = ""; + break; + case ASN_TAG_CLASS_PRIVATE: + type = "PRIVATE "; + break; } ret = snprintf(buf, size, "[%s%u]", type, ((unsigned)tag) >> 2); diff --git a/src/core/libs/supl/asn-supl/ber_tlv_tag.h b/src/core/libs/supl/asn-supl/ber_tlv_tag.h index 68e03689b..018c6f29c 100644 --- a/src/core/libs/supl/asn-supl/ber_tlv_tag.h +++ b/src/core/libs/supl/asn-supl/ber_tlv_tag.h @@ -46,7 +46,7 @@ extern "C" * >0: Number of bytes used from bufptr. tag_r will contain the tag. */ ssize_t ber_fetch_tag(const void *bufptr, size_t size, - ber_tlv_tag_t *tag_r); + ber_tlv_tag_t *tag_r); /* * This function serializes the tag (T from TLV) in BER format. diff --git a/src/core/libs/supl/asn-supl/constr_CHOICE.c b/src/core/libs/supl/asn-supl/constr_CHOICE.c index 62682ab72..7c0917700 100644 --- a/src/core/libs/supl/asn-supl/constr_CHOICE.c +++ b/src/core/libs/supl/asn-supl/constr_CHOICE.c @@ -72,7 +72,7 @@ * See the definitions. */ static int _fetch_present_idx(const void *struct_ptr, int pres_offset, - int size); + int size); static void _set_present_idx(void *struct_ptr, int offset, int size, int pres); /* @@ -112,8 +112,8 @@ static int _search4tag(const void *ap, const void *bp) * The decoder of the CHOICE type. */ asn_dec_rval_t CHOICE_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **struct_ptr, - const void *ptr, size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, void **struct_ptr, + const void *ptr, size_t size, int tag_mode) { /* * Bring closer parts of structure description. @@ -157,265 +157,265 @@ asn_dec_rval_t CHOICE_decode_ber(asn_codec_ctx_t *opt_codec_ctx, */ switch (ctx->phase) { - case 0: - /* + case 0: + /* * PHASE 0. * Check that the set of tags associated with given structure * perfectly fits our expectations. */ - if (tag_mode || td->tags_count) - { - rval = ber_check_tags(opt_codec_ctx, td, ctx, ptr, size, - tag_mode, -1, &ctx->left, 0); - if (rval.code != RC_OK) - { - ASN_DEBUG("%s tagging check failed: %d", - td->name, rval.code); - return rval; - } + if (tag_mode || td->tags_count) + { + rval = ber_check_tags(opt_codec_ctx, td, ctx, ptr, size, + tag_mode, -1, &ctx->left, 0); + if (rval.code != RC_OK) + { + ASN_DEBUG("%s tagging check failed: %d", + td->name, rval.code); + return rval; + } - if (ctx->left >= 0) - { - /* ?Subtracted below! */ - ctx->left += rval.consumed; - } - ADVANCE(rval.consumed); - } - else - { - ctx->left = -1; - } + if (ctx->left >= 0) + { + /* ?Subtracted below! */ + ctx->left += rval.consumed; + } + ADVANCE(rval.consumed); + } + else + { + ctx->left = -1; + } - NEXT_PHASE(ctx); + NEXT_PHASE(ctx); - ASN_DEBUG("Structure consumes %ld bytes, buffer %ld", - (long)ctx->left, (long)size); + ASN_DEBUG("Structure consumes %ld bytes, buffer %ld", + (long)ctx->left, (long)size); - /* Fall through */ - case 1: - /* + /* Fall through */ + case 1: + /* * Fetch the T from TLV. */ - tag_len = ber_fetch_tag(ptr, LEFT, &tlv_tag); - ASN_DEBUG("In %s CHOICE tag length %d", td->name, (int)tag_len); - switch (tag_len) - { - case 0: - if (!SIZE_VIOLATION) RETURN(RC_WMORE); - /* Fall through */ - case -1: - RETURN(RC_FAIL); - } + tag_len = ber_fetch_tag(ptr, LEFT, &tlv_tag); + ASN_DEBUG("In %s CHOICE tag length %d", td->name, (int)tag_len); + switch (tag_len) + { + case 0: + if (!SIZE_VIOLATION) RETURN(RC_WMORE); + /* Fall through */ + case -1: + RETURN(RC_FAIL); + } - do - { - asn_TYPE_tag2member_t *t2m; - asn_TYPE_tag2member_t key; + do + { + asn_TYPE_tag2member_t *t2m; + asn_TYPE_tag2member_t key; - key.el_tag = tlv_tag; - t2m = (asn_TYPE_tag2member_t *)bsearch( - &key, specs->tag2el, specs->tag2el_count, - sizeof(specs->tag2el[0]), _search4tag); - if (t2m) - { - /* + key.el_tag = tlv_tag; + t2m = (asn_TYPE_tag2member_t *)bsearch( + &key, specs->tag2el, specs->tag2el_count, + sizeof(specs->tag2el[0]), _search4tag); + if (t2m) + { + /* * Found the element corresponding to the tag. */ - NEXT_PHASE(ctx); - ctx->step = t2m->el_no; - break; - } - else if (specs->ext_start == -1) - { - ASN_DEBUG( - "Unexpected tag %s " - "in non-extensible CHOICE %s", - ber_tlv_tag_string(tlv_tag), td->name); - RETURN(RC_FAIL); - } - else - { - /* Skip this tag */ - ssize_t skip; + NEXT_PHASE(ctx); + ctx->step = t2m->el_no; + break; + } + else if (specs->ext_start == -1) + { + ASN_DEBUG( + "Unexpected tag %s " + "in non-extensible CHOICE %s", + ber_tlv_tag_string(tlv_tag), td->name); + RETURN(RC_FAIL); + } + else + { + /* Skip this tag */ + ssize_t skip; - ASN_DEBUG("Skipping unknown tag %s", - ber_tlv_tag_string(tlv_tag)); + ASN_DEBUG("Skipping unknown tag %s", + ber_tlv_tag_string(tlv_tag)); - skip = ber_skip_length( - opt_codec_ctx, BER_TLV_CONSTRUCTED(ptr), - (const char *)ptr + tag_len, - LEFT - tag_len); + skip = ber_skip_length( + opt_codec_ctx, BER_TLV_CONSTRUCTED(ptr), + (const char *)ptr + tag_len, + LEFT - tag_len); - switch (skip) - { - case 0: - if (!SIZE_VIOLATION) - RETURN(RC_WMORE); - /* Fall through */ - case -1: - RETURN(RC_FAIL); - } + switch (skip) + { + case 0: + if (!SIZE_VIOLATION) + RETURN(RC_WMORE); + /* Fall through */ + case -1: + RETURN(RC_FAIL); + } - ADVANCE(skip + tag_len); - RETURN(RC_OK); - } - } - while (0); + ADVANCE(skip + tag_len); + RETURN(RC_OK); + } + } + while (0); - case 2: - /* + case 2: + /* * PHASE 2. * Read in the element. */ - do - { - asn_TYPE_member_t *elm; /* CHOICE's element */ - void *memb_ptr; /* Pointer to the member */ - void **memb_ptr2; /* Pointer to that pointer */ + do + { + asn_TYPE_member_t *elm; /* CHOICE's element */ + void *memb_ptr; /* Pointer to the member */ + void **memb_ptr2; /* Pointer to that pointer */ - elm = &elements[ctx->step]; + elm = &elements[ctx->step]; - /* + /* * Compute the position of the member inside a * structure, and also a type of containment (it may be * contained as pointer or using inline inclusion). */ - if (elm->flags & ATF_POINTER) - { - /* Member is a pointer to another structure */ - memb_ptr2 = - (void **)((char *)st + elm->memb_offset); - } - else - { - /* + if (elm->flags & ATF_POINTER) + { + /* Member is a pointer to another structure */ + memb_ptr2 = + (void **)((char *)st + elm->memb_offset); + } + else + { + /* * A pointer to a pointer * holding the start of the structure */ - memb_ptr = (char *)st + elm->memb_offset; - memb_ptr2 = &memb_ptr; - } - /* Set presence to be able to free it properly at any + memb_ptr = (char *)st + elm->memb_offset; + memb_ptr2 = &memb_ptr; + } + /* Set presence to be able to free it properly at any * time */ - _set_present_idx(st, specs->pres_offset, - specs->pres_size, ctx->step + 1); - /* + _set_present_idx(st, specs->pres_offset, + specs->pres_size, ctx->step + 1); + /* * Invoke the member fetch routine according to member's * type */ - rval = elm->type->ber_decoder(opt_codec_ctx, elm->type, - memb_ptr2, ptr, LEFT, - elm->tag_mode); - switch (rval.code) - { - case RC_OK: - break; - case RC_WMORE: /* More data expected */ - if (!SIZE_VIOLATION) - { - ADVANCE(rval.consumed); - RETURN(RC_WMORE); - } - RETURN(RC_FAIL); - case RC_FAIL: /* Fatal error */ - RETURN(rval.code); - } /* switch(rval) */ + rval = elm->type->ber_decoder(opt_codec_ctx, elm->type, + memb_ptr2, ptr, LEFT, + elm->tag_mode); + switch (rval.code) + { + case RC_OK: + break; + case RC_WMORE: /* More data expected */ + if (!SIZE_VIOLATION) + { + ADVANCE(rval.consumed); + RETURN(RC_WMORE); + } + RETURN(RC_FAIL); + case RC_FAIL: /* Fatal error */ + RETURN(rval.code); + } /* switch(rval) */ - ADVANCE(rval.consumed); - } - while (0); + ADVANCE(rval.consumed); + } + while (0); - NEXT_PHASE(ctx); + NEXT_PHASE(ctx); - /* Fall through */ - case 3: - ASN_DEBUG("CHOICE %s Leftover: %ld, size = %ld, tm=%d, tc=%d", - td->name, (long)ctx->left, (long)size, tag_mode, - td->tags_count); + /* Fall through */ + case 3: + ASN_DEBUG("CHOICE %s Leftover: %ld, size = %ld, tm=%d, tc=%d", + td->name, (long)ctx->left, (long)size, tag_mode, + td->tags_count); - if (ctx->left > 0) - { - /* + if (ctx->left > 0) + { + /* * The type must be fully decoded * by the CHOICE member-specific decoder. */ - RETURN(RC_FAIL); - } + RETURN(RC_FAIL); + } - if (ctx->left == -1 && !(tag_mode || td->tags_count)) - { - /* + if (ctx->left == -1 && !(tag_mode || td->tags_count)) + { + /* * This is an untagged CHOICE. * It doesn't contain nothing * except for the member itself, including all its tags. * The decoding is completed. */ - NEXT_PHASE(ctx); - break; - } + NEXT_PHASE(ctx); + break; + } - /* + /* * Read in the "end of data chunks"'s. */ - while (ctx->left < 0) - { - ssize_t tl; + while (ctx->left < 0) + { + ssize_t tl; - tl = ber_fetch_tag(ptr, LEFT, &tlv_tag); - switch (tl) - { - case 0: - if (!SIZE_VIOLATION) RETURN(RC_WMORE); - /* Fall through */ - case -1: - RETURN(RC_FAIL); - } + tl = ber_fetch_tag(ptr, LEFT, &tlv_tag); + switch (tl) + { + case 0: + if (!SIZE_VIOLATION) RETURN(RC_WMORE); + /* Fall through */ + case -1: + RETURN(RC_FAIL); + } - /* + /* * Expected <0><0>... */ - if (((const uint8_t *)ptr)[0] == 0) - { - if (LEFT < 2) - { - if (SIZE_VIOLATION) - RETURN(RC_FAIL); - else - RETURN(RC_WMORE); - } - else if (((const uint8_t *)ptr)[1] == 0) - { - /* + if (((const uint8_t *)ptr)[0] == 0) + { + if (LEFT < 2) + { + if (SIZE_VIOLATION) + RETURN(RC_FAIL); + else + RETURN(RC_WMORE); + } + else if (((const uint8_t *)ptr)[1] == 0) + { + /* * Correctly finished with <0><0>. */ - ADVANCE(2); - ctx->left++; - continue; - } - } - else - { - ASN_DEBUG("Unexpected continuation in %s", - td->name); - RETURN(RC_FAIL); - } + ADVANCE(2); + ctx->left++; + continue; + } + } + else + { + ASN_DEBUG("Unexpected continuation in %s", + td->name); + RETURN(RC_FAIL); + } - /* UNREACHABLE */ - } + /* UNREACHABLE */ + } - NEXT_PHASE(ctx); - case 4: - /* No meaningful work here */ - break; + NEXT_PHASE(ctx); + case 4: + /* No meaningful work here */ + break; } RETURN(RC_OK); } asn_enc_rval_t CHOICE_encode_der(asn_TYPE_descriptor_t *td, void *sptr, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { asn_CHOICE_specifics_t *specs = (asn_CHOICE_specifics_t *)td->specifics; asn_TYPE_member_t *elm; /* CHOICE element */ @@ -482,12 +482,12 @@ asn_enc_rval_t CHOICE_encode_der(asn_TYPE_descriptor_t *td, void *sptr, /* Encode member with its tag */ erval = elm->type->der_encoder(elm->type, memb_ptr, elm->tag_mode, - elm->tag, 0, 0); + elm->tag, 0, 0); if (erval.encoded == -1) return erval; /* Encode CHOICE with parent or my own tag */ ret = der_write_tags(td, erval.encoded, tag_mode, 1, tag, cb, - app_key); + app_key); if (ret == -1) _ASN_ENCODE_FAILED; computed_size += ret; } @@ -496,11 +496,11 @@ asn_enc_rval_t CHOICE_encode_der(asn_TYPE_descriptor_t *td, void *sptr, * Encode the single underlying member. */ erval = elm->type->der_encoder(elm->type, memb_ptr, elm->tag_mode, elm->tag, - cb, app_key); + cb, app_key); if (erval.encoded == -1) return erval; ASN_DEBUG("Encoded CHOICE member in %ld bytes (+%ld)", (long)erval.encoded, - (long)computed_size); + (long)computed_size); erval.encoded += computed_size; @@ -508,7 +508,7 @@ asn_enc_rval_t CHOICE_encode_der(asn_TYPE_descriptor_t *td, void *sptr, } ber_tlv_tag_t CHOICE_outmost_tag(asn_TYPE_descriptor_t *td, const void *ptr, - int tag_mode, ber_tlv_tag_t tag) + int tag_mode, ber_tlv_tag_t tag) { asn_CHOICE_specifics_t *specs = (asn_CHOICE_specifics_t *)td->specifics; int present; @@ -540,7 +540,7 @@ ber_tlv_tag_t CHOICE_outmost_tag(asn_TYPE_descriptor_t *td, const void *ptr, } return asn_TYPE_outmost_tag(elm->type, memb_ptr, elm->tag_mode, - elm->tag); + elm->tag); } else { @@ -549,7 +549,7 @@ ber_tlv_tag_t CHOICE_outmost_tag(asn_TYPE_descriptor_t *td, const void *ptr, } int CHOICE_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { asn_CHOICE_specifics_t *specs = (asn_CHOICE_specifics_t *)td->specifics; int present; @@ -557,7 +557,7 @@ int CHOICE_constraint(asn_TYPE_descriptor_t *td, const void *sptr, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -578,10 +578,10 @@ int CHOICE_constraint(asn_TYPE_descriptor_t *td, const void *sptr, { if (elm->optional) return 0; _ASN_CTFAIL(app_key, td, sptr, - "%s: mandatory CHOICE element %s " - "absent (%s:%d)", - td->name, elm->name, __FILE__, - __LINE__); + "%s: mandatory CHOICE element %s " + "absent (%s:%d)", + td->name, elm->name, __FILE__, + __LINE__); return -1; } } @@ -594,12 +594,12 @@ int CHOICE_constraint(asn_TYPE_descriptor_t *td, const void *sptr, if (elm->memb_constraints) { return elm->memb_constraints(elm->type, memb_ptr, ctfailcb, - app_key); + app_key); } else { int ret = elm->type->check_constraints(elm->type, memb_ptr, - ctfailcb, app_key); + ctfailcb, app_key); /* * Cannot inherit it eralier: * need to make sure we get the updated version. @@ -611,8 +611,8 @@ int CHOICE_constraint(asn_TYPE_descriptor_t *td, const void *sptr, else { _ASN_CTFAIL(app_key, td, sptr, - "%s: no CHOICE element given (%s:%d)", td->name, - __FILE__, __LINE__); + "%s: no CHOICE element given (%s:%d)", td->name, + __FILE__, __LINE__); return -1; } } @@ -632,9 +632,9 @@ int CHOICE_constraint(asn_TYPE_descriptor_t *td, const void *sptr, * Decode the XER (XML) data. */ asn_dec_rval_t CHOICE_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **struct_ptr, - const char *opt_mname, const void *buf_ptr, - size_t size) + asn_TYPE_descriptor_t *td, void **struct_ptr, + const char *opt_mname, const void *buf_ptr, + size_t size) { /* * Bring closer parts of structure description. @@ -709,17 +709,17 @@ asn_dec_rval_t CHOICE_decode_xer(asn_codec_ctx_t *opt_codec_ctx, /* Start/Continue decoding the inner member */ tmprval = elm->type->xer_decoder(opt_codec_ctx, elm->type, - memb_ptr2, elm->name, - buf_ptr, size); + memb_ptr2, elm->name, + buf_ptr, size); XER_ADVANCE(tmprval.consumed); ASN_DEBUG("XER/CHOICE: itdf: [%s] code=%d", elm->type->name, - tmprval.code); + tmprval.code); if (tmprval.code != RC_OK) RETURN(tmprval.code); assert(_fetch_present_idx(st, specs->pres_offset, - specs->pres_size) == 0); + specs->pres_size) == 0); /* Record what we've got */ _set_present_idx(st, specs->pres_offset, specs->pres_size, - edx + 1); + edx + 1); ctx->phase = 3; /* Fall through */ } @@ -737,29 +737,29 @@ asn_dec_rval_t CHOICE_decode_xer(asn_codec_ctx_t *opt_codec_ctx, ch_size = xer_next_token(&ctx->context, buf_ptr, size, &ch_type); switch (ch_size) { - case -1: - RETURN(RC_FAIL); - case 0: - RETURN(RC_WMORE); - default: - switch (ch_type) - { - case PXER_COMMENT: /* Got XML comment */ - case PXER_TEXT: /* Ignore free-standing text */ - XER_ADVANCE(ch_size); /* Skip silently */ - continue; - case PXER_TAG: - break; /* Check the rest down there */ - } + case -1: + RETURN(RC_FAIL); + case 0: + RETURN(RC_WMORE); + default: + switch (ch_type) + { + case PXER_COMMENT: /* Got XML comment */ + case PXER_TEXT: /* Ignore free-standing text */ + XER_ADVANCE(ch_size); /* Skip silently */ + continue; + case PXER_TAG: + break; /* Check the rest down there */ + } } tcv = xer_check_tag(buf_ptr, ch_size, xml_tag); ASN_DEBUG("XER/CHOICE checked [%c%c%c%c] vs [%s], tcv=%d", - ch_size > 0 ? ((const uint8_t *)buf_ptr)[0] : '?', - ch_size > 1 ? ((const uint8_t *)buf_ptr)[1] : '?', - ch_size > 2 ? ((const uint8_t *)buf_ptr)[2] : '?', - ch_size > 3 ? ((const uint8_t *)buf_ptr)[3] : '?', - xml_tag, tcv); + ch_size > 0 ? ((const uint8_t *)buf_ptr)[0] : '?', + ch_size > 1 ? ((const uint8_t *)buf_ptr)[1] : '?', + ch_size > 2 ? ((const uint8_t *)buf_ptr)[2] : '?', + ch_size > 3 ? ((const uint8_t *)buf_ptr)[3] : '?', + xml_tag, tcv); /* Skip the extensions section */ if (ctx->phase == 4) @@ -767,99 +767,99 @@ asn_dec_rval_t CHOICE_decode_xer(asn_codec_ctx_t *opt_codec_ctx, ASN_DEBUG("skip_unknown(%d, %ld)", tcv, (long)ctx->left); switch (xer_skip_unknown(tcv, &ctx->left)) { - case -1: - ctx->phase = 5; - RETURN(RC_FAIL); - continue; - case 1: - ctx->phase = 3; - /* Fall through */ - case 0: - XER_ADVANCE(ch_size); - continue; - case 2: - ctx->phase = 3; - break; + case -1: + ctx->phase = 5; + RETURN(RC_FAIL); + continue; + case 1: + ctx->phase = 3; + /* Fall through */ + case 0: + XER_ADVANCE(ch_size); + continue; + case 2: + ctx->phase = 3; + break; } } switch (tcv) { - case XCT_BOTH: - break; /* No CHOICE? */ - case XCT_CLOSING: - if (ctx->phase != 3) break; - XER_ADVANCE(ch_size); - ctx->phase = 5; /* Phase out */ - RETURN(RC_OK); - case XCT_OPENING: - if (ctx->phase == 0) - { - XER_ADVANCE(ch_size); - ctx->phase = 1; /* Processing body phase */ - continue; - } - /* Fall through */ - case XCT_UNKNOWN_OP: - case XCT_UNKNOWN_BO: + case XCT_BOTH: + break; /* No CHOICE? */ + case XCT_CLOSING: + if (ctx->phase != 3) break; + XER_ADVANCE(ch_size); + ctx->phase = 5; /* Phase out */ + RETURN(RC_OK); + case XCT_OPENING: + if (ctx->phase == 0) + { + XER_ADVANCE(ch_size); + ctx->phase = 1; /* Processing body phase */ + continue; + } + /* Fall through */ + case XCT_UNKNOWN_OP: + case XCT_UNKNOWN_BO: - if (ctx->phase != 1) break; /* Really unexpected */ + if (ctx->phase != 1) break; /* Really unexpected */ - /* + /* * Search which inner member corresponds to this tag. */ - for (edx = 0; edx < td->elements_count; edx++) - { - elm = &td->elements[edx]; - tcv = - xer_check_tag(buf_ptr, ch_size, elm->name); - switch (tcv) - { - case XCT_BOTH: - case XCT_OPENING: - /* + for (edx = 0; edx < td->elements_count; edx++) + { + elm = &td->elements[edx]; + tcv = + xer_check_tag(buf_ptr, ch_size, elm->name); + switch (tcv) + { + case XCT_BOTH: + case XCT_OPENING: + /* * Process this member. */ - ctx->step = edx; - ctx->phase = 2; - break; - case XCT_UNKNOWN_OP: - case XCT_UNKNOWN_BO: - continue; - default: - edx = td->elements_count; - break; /* Phase out */ - } - break; - } - if (edx != td->elements_count) continue; + ctx->step = edx; + ctx->phase = 2; + break; + case XCT_UNKNOWN_OP: + case XCT_UNKNOWN_BO: + continue; + default: + edx = td->elements_count; + break; /* Phase out */ + } + break; + } + if (edx != td->elements_count) continue; - /* It is expected extension */ - if (specs->ext_start != -1) - { - ASN_DEBUG("Got anticipated extension"); - /* + /* It is expected extension */ + if (specs->ext_start != -1) + { + ASN_DEBUG("Got anticipated extension"); + /* * Check for (XCT_BOTH or XCT_UNKNOWN_BO) * By using a mask. Only record a pure * tags. */ - if (tcv & XCT_CLOSING) - { - /* Found without body */ - ctx->phase = 3; /* Terminating */ - } - else - { - ctx->left = 1; - ctx->phase = 4; /* Skip ...'s */ - } - XER_ADVANCE(ch_size); - continue; - } + if (tcv & XCT_CLOSING) + { + /* Found without body */ + ctx->phase = 3; /* Terminating */ + } + else + { + ctx->left = 1; + ctx->phase = 4; /* Skip ...'s */ + } + XER_ADVANCE(ch_size); + continue; + } - /* Fall through */ - default: - break; + /* Fall through */ + default: + break; } ASN_DEBUG( @@ -878,8 +878,8 @@ asn_dec_rval_t CHOICE_decode_xer(asn_codec_ctx_t *opt_codec_ctx, } asn_enc_rval_t CHOICE_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { asn_CHOICE_specifics_t *specs = (asn_CHOICE_specifics_t *)td->specifics; asn_enc_rval_t er; @@ -920,7 +920,7 @@ asn_enc_rval_t CHOICE_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, _ASN_CALLBACK3("<", 1, mname, mlen, ">", 1); tmper = elm->type->xer_encoder(elm->type, memb_ptr, ilevel + 1, - flags, cb, app_key); + flags, cb, app_key); if (tmper.encoded == -1) return tmper; _ASN_CALLBACK3("", 1); @@ -936,9 +936,9 @@ cb_failed: } asn_dec_rval_t CHOICE_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd) { asn_CHOICE_specifics_t *specs = (asn_CHOICE_specifics_t *)td->specifics; asn_dec_rval_t rv; @@ -979,7 +979,7 @@ asn_dec_rval_t CHOICE_decode_uper(asn_codec_ctx_t *opt_codec_ctx, value = per_get_few_bits(pd, ct->range_bits); if (value < 0) _ASN_DECODE_STARVED; ASN_DEBUG("CHOICE %s got index %d in range %d", td->name, value, - ct->range_bits); + ct->range_bits); if (value > ct->upper_bound) _ASN_DECODE_FAILED; } else @@ -1013,23 +1013,23 @@ asn_dec_rval_t CHOICE_decode_uper(asn_codec_ctx_t *opt_codec_ctx, if (ct && ct->range_bits >= 0) { rv = elm->type->uper_decoder(opt_codec_ctx, elm->type, - elm->per_constraints, memb_ptr2, pd); + elm->per_constraints, memb_ptr2, pd); } else { rv = uper_open_type_get(opt_codec_ctx, elm->type, - elm->per_constraints, memb_ptr2, pd); + elm->per_constraints, memb_ptr2, pd); } if (rv.code != RC_OK) ASN_DEBUG("Failed to decode %s in %s (CHOICE) %d", elm->name, td->name, - rv.code); + rv.code); return rv; } asn_enc_rval_t CHOICE_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *sptr, asn_per_outp_t *po) + asn_per_constraints_t *constraints, + void *sptr, asn_per_outp_t *po) { asn_CHOICE_specifics_t *specs = (asn_CHOICE_specifics_t *)td->specifics; asn_TYPE_member_t *elm; /* CHOICE's element */ @@ -1100,7 +1100,7 @@ asn_enc_rval_t CHOICE_encode_uper(asn_TYPE_descriptor_t *td, _ASN_ENCODE_FAILED; return elm->type->uper_encoder(elm->type, elm->per_constraints, - memb_ptr, po); + memb_ptr, po); } else { @@ -1109,7 +1109,7 @@ asn_enc_rval_t CHOICE_encode_uper(asn_TYPE_descriptor_t *td, if (uper_put_nsnnwn(po, present - specs->ext_start)) _ASN_ENCODE_FAILED; if (uper_open_type_put(elm->type, elm->per_constraints, memb_ptr, - po)) + po)) _ASN_ENCODE_FAILED; rval.encoded = 0; _ASN_ENCODED_OK(rval); @@ -1117,7 +1117,7 @@ asn_enc_rval_t CHOICE_encode_uper(asn_TYPE_descriptor_t *td, } int CHOICE_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { asn_CHOICE_specifics_t *specs = (asn_CHOICE_specifics_t *)td->specifics; int present; @@ -1159,7 +1159,7 @@ int CHOICE_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, } return elm->type->print_struct(elm->type, memb_ptr, ilevel, cb, - app_key); + app_key); } else { @@ -1217,7 +1217,7 @@ void CHOICE_free(asn_TYPE_descriptor_t *td, void *ptr, int contents_only) * produce packed code. */ static int _fetch_present_idx(const void *struct_ptr, int pres_offset, - int pres_size) + int pres_size) { const void *present_ptr; int present; @@ -1226,43 +1226,43 @@ static int _fetch_present_idx(const void *struct_ptr, int pres_offset, switch (pres_size) { - case sizeof(int): - present = *(const int *)present_ptr; - break; - case sizeof(short): - present = *(const short *)present_ptr; - break; - case sizeof(char): - present = *(const char *)present_ptr; - break; - default: - /* ANSI C mandates enum to be equivalent to integer */ - assert(pres_size != sizeof(int)); - return 0; /* If not aborted, pass back safe value */ + case sizeof(int): + present = *(const int *)present_ptr; + break; + case sizeof(short): + present = *(const short *)present_ptr; + break; + case sizeof(char): + present = *(const char *)present_ptr; + break; + default: + /* ANSI C mandates enum to be equivalent to integer */ + assert(pres_size != sizeof(int)); + return 0; /* If not aborted, pass back safe value */ } return present; } static void _set_present_idx(void *struct_ptr, int pres_offset, int pres_size, - int present) + int present) { void *present_ptr; present_ptr = ((char *)struct_ptr) + pres_offset; switch (pres_size) { - case sizeof(int): - *(int *)present_ptr = present; - break; - case sizeof(short): - *(short *)present_ptr = present; - break; - case sizeof(char): - *(char *)present_ptr = present; - break; - default: - /* ANSI C mandates enum to be equivalent to integer */ - assert(pres_size != sizeof(int)); + case sizeof(int): + *(int *)present_ptr = present; + break; + case sizeof(short): + *(short *)present_ptr = present; + break; + case sizeof(char): + *(char *)present_ptr = present; + break; + default: + /* ANSI C mandates enum to be equivalent to integer */ + assert(pres_size != sizeof(int)); } } diff --git a/src/core/libs/supl/asn-supl/constr_SEQUENCE.c b/src/core/libs/supl/asn-supl/constr_SEQUENCE.c index 21b3c0a7c..ddf0d87fd 100644 --- a/src/core/libs/supl/asn-supl/constr_SEQUENCE.c +++ b/src/core/libs/supl/asn-supl/constr_SEQUENCE.c @@ -125,8 +125,8 @@ static int _t2e_cmp(const void *ap, const void *bp) * The decoder of the SEQUENCE type. */ asn_dec_rval_t SEQUENCE_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **struct_ptr, - const void *ptr, size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, void **struct_ptr, + const void *ptr, size_t size, int tag_mode) { /* * Bring closer parts of structure description. @@ -170,34 +170,34 @@ asn_dec_rval_t SEQUENCE_decode_ber(asn_codec_ctx_t *opt_codec_ctx, */ switch (ctx->phase) { - case 0: - /* + case 0: + /* * PHASE 0. * Check that the set of tags associated with given structure * perfectly fits our expectations. */ - rval = ber_check_tags(opt_codec_ctx, td, ctx, ptr, size, - tag_mode, 1, &ctx->left, 0); - if (rval.code != RC_OK) - { - ASN_DEBUG("%s tagging check failed: %d", td->name, - rval.code); - return rval; - } + rval = ber_check_tags(opt_codec_ctx, td, ctx, ptr, size, + tag_mode, 1, &ctx->left, 0); + if (rval.code != RC_OK) + { + ASN_DEBUG("%s tagging check failed: %d", td->name, + rval.code); + return rval; + } - if (ctx->left >= 0) - ctx->left += rval.consumed; /* ?Subtracted below! */ - ADVANCE(rval.consumed); + if (ctx->left >= 0) + ctx->left += rval.consumed; /* ?Subtracted below! */ + ADVANCE(rval.consumed); - NEXT_PHASE(ctx); + NEXT_PHASE(ctx); - ASN_DEBUG("Structure consumes %ld bytes, buffer %ld", - (long)ctx->left, (long)size); + ASN_DEBUG("Structure consumes %ld bytes, buffer %ld", + (long)ctx->left, (long)size); - /* Fall through */ - case 1: - /* + /* Fall through */ + case 1: + /* * PHASE 1. * From the place where we've left it previously, * try to decode the next member from the list of @@ -207,380 +207,380 @@ asn_dec_rval_t SEQUENCE_decode_ber(asn_codec_ctx_t *opt_codec_ctx, * that member: * step = ( * 2 + ). */ - for (edx = (ctx->step >> 1); edx < td->elements_count; - edx++, ctx->step = (ctx->step & ~1) + 2) - { - void *memb_ptr; /* Pointer to the member */ - void **memb_ptr2; /* Pointer to that pointer */ - ssize_t tag_len; /* Length of TLV's T */ - int opt_edx_end; /* Next non-optional element */ - int use_bsearch; - int n; + for (edx = (ctx->step >> 1); edx < td->elements_count; + edx++, ctx->step = (ctx->step & ~1) + 2) + { + void *memb_ptr; /* Pointer to the member */ + void **memb_ptr2; /* Pointer to that pointer */ + ssize_t tag_len; /* Length of TLV's T */ + int opt_edx_end; /* Next non-optional element */ + int use_bsearch; + int n; - if (ctx->step & 1) goto microphase2; + if (ctx->step & 1) goto microphase2; - /* + /* * MICROPHASE 1: Synchronize decoding. */ - ASN_DEBUG( - "In %s SEQUENCE left %d, edx=%d flags=%d" - " opt=%d ec=%d", - td->name, (int)ctx->left, edx, elements[edx].flags, - elements[edx].optional, td->elements_count); + ASN_DEBUG( + "In %s SEQUENCE left %d, edx=%d flags=%d" + " opt=%d ec=%d", + td->name, (int)ctx->left, edx, elements[edx].flags, + elements[edx].optional, td->elements_count); - if (ctx->left == 0 /* No more stuff is expected */ - && ( - /* Explicit OPTIONAL specification reaches + if (ctx->left == 0 /* No more stuff is expected */ + && ( + /* Explicit OPTIONAL specification reaches the end */ - (edx + elements[edx].optional == - td->elements_count) || - /* All extensions are optional */ - (IN_EXTENSION_GROUP(specs, edx) && - specs->ext_before > td->elements_count))) - { - ASN_DEBUG("End of SEQUENCE %s", td->name); - /* + (edx + elements[edx].optional == + td->elements_count) || + /* All extensions are optional */ + (IN_EXTENSION_GROUP(specs, edx) && + specs->ext_before > td->elements_count))) + { + ASN_DEBUG("End of SEQUENCE %s", td->name); + /* * Found the legitimate end of the structure. */ - PHASE_OUT(ctx); - RETURN(RC_OK); - } + PHASE_OUT(ctx); + RETURN(RC_OK); + } - /* + /* * Fetch the T from TLV. */ - tag_len = ber_fetch_tag(ptr, LEFT, &tlv_tag); - ASN_DEBUG( - "Current tag in %s SEQUENCE for element %d " - "(%s) is %s encoded in %d bytes, of frame %ld", - td->name, edx, elements[edx].name, - ber_tlv_tag_string(tlv_tag), (int)tag_len, - (long)LEFT); - switch (tag_len) - { - case 0: - if (!SIZE_VIOLATION) RETURN(RC_WMORE); - /* Fall through */ - case -1: - RETURN(RC_FAIL); - } + tag_len = ber_fetch_tag(ptr, LEFT, &tlv_tag); + ASN_DEBUG( + "Current tag in %s SEQUENCE for element %d " + "(%s) is %s encoded in %d bytes, of frame %ld", + td->name, edx, elements[edx].name, + ber_tlv_tag_string(tlv_tag), (int)tag_len, + (long)LEFT); + switch (tag_len) + { + case 0: + if (!SIZE_VIOLATION) RETURN(RC_WMORE); + /* Fall through */ + case -1: + RETURN(RC_FAIL); + } - if (ctx->left < 0 && ((const uint8_t *)ptr)[0] == 0) - { - if (LEFT < 2) - { - if (SIZE_VIOLATION) - RETURN(RC_FAIL); - else - RETURN(RC_WMORE); - } - else if (((const uint8_t *)ptr)[1] == 0) - { - ASN_DEBUG("edx = %d, opt = %d, ec=%d", - edx, elements[edx].optional, - td->elements_count); - if ((edx + elements[edx].optional == - td->elements_count) || - (IN_EXTENSION_GROUP(specs, edx) && - specs->ext_before > - td->elements_count)) - { - /* + if (ctx->left < 0 && ((const uint8_t *)ptr)[0] == 0) + { + if (LEFT < 2) + { + if (SIZE_VIOLATION) + RETURN(RC_FAIL); + else + RETURN(RC_WMORE); + } + else if (((const uint8_t *)ptr)[1] == 0) + { + ASN_DEBUG("edx = %d, opt = %d, ec=%d", + edx, elements[edx].optional, + td->elements_count); + if ((edx + elements[edx].optional == + td->elements_count) || + (IN_EXTENSION_GROUP(specs, edx) && + specs->ext_before > + td->elements_count)) + { + /* * Yeah, baby! Found the * terminator of the indefinite * length structure. */ - /* + /* * Proceed to the canonical * finalization function. * No advancing is necessary. */ - goto phase3; - } - } - } + goto phase3; + } + } + } - /* + /* * Find the next available type with this tag. */ - use_bsearch = 0; - opt_edx_end = edx + elements[edx].optional + 1; - if (opt_edx_end > td->elements_count) - opt_edx_end = td->elements_count; /* Cap */ - else if (opt_edx_end - edx > 8) - { - /* Limit the scope of linear search... */ - opt_edx_end = edx + 8; - use_bsearch = 1; - /* ... and resort to bsearch() */ - } - for (n = edx; n < opt_edx_end; n++) - { - if (BER_TAGS_EQUAL(tlv_tag, elements[n].tag)) - { - /* + use_bsearch = 0; + opt_edx_end = edx + elements[edx].optional + 1; + if (opt_edx_end > td->elements_count) + opt_edx_end = td->elements_count; /* Cap */ + else if (opt_edx_end - edx > 8) + { + /* Limit the scope of linear search... */ + opt_edx_end = edx + 8; + use_bsearch = 1; + /* ... and resort to bsearch() */ + } + for (n = edx; n < opt_edx_end; n++) + { + if (BER_TAGS_EQUAL(tlv_tag, elements[n].tag)) + { + /* * Found element corresponding to the * tag being looked at. Reposition over * the right element. */ - edx = n; - ctx->step = 1 + 2 * edx; /* Remember! */ - goto microphase2; - } - else if (elements[n].flags & ATF_OPEN_TYPE) - { - /* + edx = n; + ctx->step = 1 + 2 * edx; /* Remember! */ + goto microphase2; + } + else if (elements[n].flags & ATF_OPEN_TYPE) + { + /* * This is the ANY type, which may bear * any flag whatsoever. */ - edx = n; - ctx->step = 1 + 2 * edx; /* Remember! */ - goto microphase2; - } - else if (elements[n].tag == (ber_tlv_tag_t)-1) - { - use_bsearch = 1; - break; - } - } - if (use_bsearch) - { - /* + edx = n; + ctx->step = 1 + 2 * edx; /* Remember! */ + goto microphase2; + } + else if (elements[n].tag == (ber_tlv_tag_t)-1) + { + use_bsearch = 1; + break; + } + } + if (use_bsearch) + { + /* * Resort to a binary search over * sorted array of tags. */ - asn_TYPE_tag2member_t *t2m; - asn_TYPE_tag2member_t key; - key.el_tag = tlv_tag; - key.el_no = edx; - t2m = (asn_TYPE_tag2member_t *)bsearch( - &key, specs->tag2el, specs->tag2el_count, - sizeof(specs->tag2el[0]), _t2e_cmp); - if (t2m) - { - asn_TYPE_tag2member_t *best = 0; - asn_TYPE_tag2member_t *t2m_f; - asn_TYPE_tag2member_t *t2m_l; - int edx_max = - edx + elements[edx].optional; - /* + asn_TYPE_tag2member_t *t2m; + asn_TYPE_tag2member_t key; + key.el_tag = tlv_tag; + key.el_no = edx; + t2m = (asn_TYPE_tag2member_t *)bsearch( + &key, specs->tag2el, specs->tag2el_count, + sizeof(specs->tag2el[0]), _t2e_cmp); + if (t2m) + { + asn_TYPE_tag2member_t *best = 0; + asn_TYPE_tag2member_t *t2m_f; + asn_TYPE_tag2member_t *t2m_l; + int edx_max = + edx + elements[edx].optional; + /* * Rewind to the first element with that * tag, `cause bsearch() does not * guarantee order. */ - t2m_f = t2m + t2m->toff_first; - t2m_l = t2m + t2m->toff_last; - for (t2m = t2m_f; t2m <= t2m_l; t2m++) - { - if (t2m->el_no > edx_max) break; - if (t2m->el_no < edx) continue; - best = t2m; - } - if (best) - { - edx = best->el_no; - ctx->step = 1 + 2 * edx; - goto microphase2; - } - } - n = opt_edx_end; - } - if (n == opt_edx_end) - { - /* + t2m_f = t2m + t2m->toff_first; + t2m_l = t2m + t2m->toff_last; + for (t2m = t2m_f; t2m <= t2m_l; t2m++) + { + if (t2m->el_no > edx_max) break; + if (t2m->el_no < edx) continue; + best = t2m; + } + if (best) + { + edx = best->el_no; + ctx->step = 1 + 2 * edx; + goto microphase2; + } + } + n = opt_edx_end; + } + if (n == opt_edx_end) + { + /* * If tag is unknown, it may be either * an unknown (thus, incorrect) tag, * or an extension (...), * or an end of the indefinite-length structure. */ - if (!IN_EXTENSION_GROUP( - specs, edx + elements[edx].optional)) - { - ASN_DEBUG("Unexpected tag %s (at %d)", - ber_tlv_tag_string(tlv_tag), - edx); - ASN_DEBUG("Expected tag %s (%s)%s", - ber_tlv_tag_string( - elements[edx].tag), - elements[edx].name, - elements[edx].optional - ? " or alternatives" - : ""); - RETURN(RC_FAIL); - } - else - { - /* Skip this tag */ - ssize_t skip; - edx += elements[edx].optional; + if (!IN_EXTENSION_GROUP( + specs, edx + elements[edx].optional)) + { + ASN_DEBUG("Unexpected tag %s (at %d)", + ber_tlv_tag_string(tlv_tag), + edx); + ASN_DEBUG("Expected tag %s (%s)%s", + ber_tlv_tag_string( + elements[edx].tag), + elements[edx].name, + elements[edx].optional + ? " or alternatives" + : ""); + RETURN(RC_FAIL); + } + else + { + /* Skip this tag */ + ssize_t skip; + edx += elements[edx].optional; - ASN_DEBUG( - "Skipping unexpected %s (at %d)", - ber_tlv_tag_string(tlv_tag), edx); - skip = ber_skip_length( - opt_codec_ctx, - BER_TLV_CONSTRUCTED(ptr), - (const char *)ptr + tag_len, - LEFT - tag_len); - ASN_DEBUG("Skip length %d in %s", - (int)skip, td->name); - switch (skip) - { - case 0: - if (!SIZE_VIOLATION) - RETURN(RC_WMORE); - /* Fall through */ - case -1: - RETURN(RC_FAIL); - } + ASN_DEBUG( + "Skipping unexpected %s (at %d)", + ber_tlv_tag_string(tlv_tag), edx); + skip = ber_skip_length( + opt_codec_ctx, + BER_TLV_CONSTRUCTED(ptr), + (const char *)ptr + tag_len, + LEFT - tag_len); + ASN_DEBUG("Skip length %d in %s", + (int)skip, td->name); + switch (skip) + { + case 0: + if (!SIZE_VIOLATION) + RETURN(RC_WMORE); + /* Fall through */ + case -1: + RETURN(RC_FAIL); + } - ADVANCE(skip + tag_len); - ctx->step -= 2; - edx--; - continue; /* Try again with the next tag + ADVANCE(skip + tag_len); + ctx->step -= 2; + edx--; + continue; /* Try again with the next tag */ - } - } + } + } - /* + /* * MICROPHASE 2: Invoke the member-specific decoder. */ - ctx->step |= 1; /* Confirm entering next microphase */ - microphase2: - ASN_DEBUG("Inside SEQUENCE %s MF2", td->name); + ctx->step |= 1; /* Confirm entering next microphase */ + microphase2: + ASN_DEBUG("Inside SEQUENCE %s MF2", td->name); - /* + /* * Compute the position of the member inside a * structure, and also a type of containment (it may be * contained as pointer or using inline inclusion). */ - if (elements[edx].flags & ATF_POINTER) - { - /* Member is a pointer to another structure */ - memb_ptr2 = - (void **)((char *)st + - elements[edx].memb_offset); - } - else - { - /* + if (elements[edx].flags & ATF_POINTER) + { + /* Member is a pointer to another structure */ + memb_ptr2 = + (void **)((char *)st + + elements[edx].memb_offset); + } + else + { + /* * A pointer to a pointer * holding the start of the structure */ - memb_ptr = - (char *)st + elements[edx].memb_offset; - memb_ptr2 = &memb_ptr; - } - /* + memb_ptr = + (char *)st + elements[edx].memb_offset; + memb_ptr2 = &memb_ptr; + } + /* * Invoke the member fetch routine according to member's * type */ - rval = elements[edx].type->ber_decoder( - opt_codec_ctx, elements[edx].type, memb_ptr2, ptr, - LEFT, elements[edx].tag_mode); - ASN_DEBUG( - "In %s SEQUENCE decoded %d %s of %d " - "in %d bytes rval.code %d, size=%d", - td->name, edx, elements[edx].type->name, (int)LEFT, - (int)rval.consumed, rval.code, (int)size); - switch (rval.code) - { - case RC_OK: - break; - case RC_WMORE: /* More data expected */ - if (!SIZE_VIOLATION) - { - ADVANCE(rval.consumed); - RETURN(RC_WMORE); - } - ASN_DEBUG( - "Size violation (c->l=%ld <= s=%ld)", - (long)ctx->left, (long)size); - /* Fall through */ - case RC_FAIL: /* Fatal error */ - RETURN(RC_FAIL); - } /* switch(rval) */ + rval = elements[edx].type->ber_decoder( + opt_codec_ctx, elements[edx].type, memb_ptr2, ptr, + LEFT, elements[edx].tag_mode); + ASN_DEBUG( + "In %s SEQUENCE decoded %d %s of %d " + "in %d bytes rval.code %d, size=%d", + td->name, edx, elements[edx].type->name, (int)LEFT, + (int)rval.consumed, rval.code, (int)size); + switch (rval.code) + { + case RC_OK: + break; + case RC_WMORE: /* More data expected */ + if (!SIZE_VIOLATION) + { + ADVANCE(rval.consumed); + RETURN(RC_WMORE); + } + ASN_DEBUG( + "Size violation (c->l=%ld <= s=%ld)", + (long)ctx->left, (long)size); + /* Fall through */ + case RC_FAIL: /* Fatal error */ + RETURN(RC_FAIL); + } /* switch(rval) */ - ADVANCE(rval.consumed); - } /* for(all structure members) */ + ADVANCE(rval.consumed); + } /* for(all structure members) */ - phase3: - ctx->phase = 3; - case 3: /* 00 and other tags expected */ - case 4: /* only 00's expected */ + phase3: + ctx->phase = 3; + case 3: /* 00 and other tags expected */ + case 4: /* only 00's expected */ - ASN_DEBUG("SEQUENCE %s Leftover: %ld, size = %ld", td->name, - (long)ctx->left, (long)size); + ASN_DEBUG("SEQUENCE %s Leftover: %ld, size = %ld", td->name, + (long)ctx->left, (long)size); - /* + /* * Skip everything until the end of the SEQUENCE. */ - while (ctx->left) - { - ssize_t tl; - ssize_t ll; + while (ctx->left) + { + ssize_t tl; + ssize_t ll; - tl = ber_fetch_tag(ptr, LEFT, &tlv_tag); - switch (tl) - { - case 0: - if (!SIZE_VIOLATION) RETURN(RC_WMORE); - /* Fall through */ - case -1: - RETURN(RC_FAIL); - } + tl = ber_fetch_tag(ptr, LEFT, &tlv_tag); + switch (tl) + { + case 0: + if (!SIZE_VIOLATION) RETURN(RC_WMORE); + /* Fall through */ + case -1: + RETURN(RC_FAIL); + } - /* + /* * If expected <0><0>... */ - if (ctx->left < 0 && ((const uint8_t *)ptr)[0] == 0) - { - if (LEFT < 2) - { - if (SIZE_VIOLATION) - RETURN(RC_FAIL); - else - RETURN(RC_WMORE); - } - else if (((const uint8_t *)ptr)[1] == 0) - { - /* + if (ctx->left < 0 && ((const uint8_t *)ptr)[0] == 0) + { + if (LEFT < 2) + { + if (SIZE_VIOLATION) + RETURN(RC_FAIL); + else + RETURN(RC_WMORE); + } + else if (((const uint8_t *)ptr)[1] == 0) + { + /* * Correctly finished with <0><0>. */ - ADVANCE(2); - ctx->left++; - ctx->phase = 4; - continue; - } - } + ADVANCE(2); + ctx->left++; + ctx->phase = 4; + continue; + } + } - if (!IN_EXTENSION_GROUP(specs, td->elements_count) || - ctx->phase == 4) - { - ASN_DEBUG( - "Unexpected continuation " - "of a non-extensible type " - "%s (SEQUENCE): %s", - td->name, ber_tlv_tag_string(tlv_tag)); - RETURN(RC_FAIL); - } + if (!IN_EXTENSION_GROUP(specs, td->elements_count) || + ctx->phase == 4) + { + ASN_DEBUG( + "Unexpected continuation " + "of a non-extensible type " + "%s (SEQUENCE): %s", + td->name, ber_tlv_tag_string(tlv_tag)); + RETURN(RC_FAIL); + } - ll = ber_skip_length(opt_codec_ctx, - BER_TLV_CONSTRUCTED(ptr), - (const char *)ptr + tl, LEFT - tl); - switch (ll) - { - case 0: - if (!SIZE_VIOLATION) RETURN(RC_WMORE); - /* Fall through */ - case -1: - RETURN(RC_FAIL); - } + ll = ber_skip_length(opt_codec_ctx, + BER_TLV_CONSTRUCTED(ptr), + (const char *)ptr + tl, LEFT - tl); + switch (ll) + { + case 0: + if (!SIZE_VIOLATION) RETURN(RC_WMORE); + /* Fall through */ + case -1: + RETURN(RC_FAIL); + } - ADVANCE(tl + ll); - } + ADVANCE(tl + ll); + } - PHASE_OUT(ctx); + PHASE_OUT(ctx); } RETURN(RC_OK); @@ -590,8 +590,8 @@ asn_dec_rval_t SEQUENCE_decode_ber(asn_codec_ctx_t *opt_codec_ctx, * The DER encoder of the SEQUENCE type. */ asn_enc_rval_t SEQUENCE_encode_der(asn_TYPE_descriptor_t *td, void *sptr, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { size_t computed_size = 0; asn_enc_rval_t erval; @@ -622,11 +622,11 @@ asn_enc_rval_t SEQUENCE_encode_der(asn_TYPE_descriptor_t *td, void *sptr, memb_ptr = (void *)((char *)sptr + elm->memb_offset); } erval = elm->type->der_encoder(elm->type, memb_ptr, elm->tag_mode, - elm->tag, 0, 0); + elm->tag, 0, 0); if (erval.encoded == -1) return erval; computed_size += erval.encoded; ASN_DEBUG("Member %d %s estimated %ld bytes", edx, elm->name, - (long)erval.encoded); + (long)erval.encoded); } /* @@ -662,7 +662,7 @@ asn_enc_rval_t SEQUENCE_encode_der(asn_TYPE_descriptor_t *td, void *sptr, if (tmperval.encoded == -1) return tmperval; computed_size -= tmperval.encoded; ASN_DEBUG("Member %d %s of SEQUENCE %s encoded in %ld bytes", edx, - elm->name, td->name, (long)tmperval.encoded); + elm->name, td->name, (long)tmperval.encoded); } if (computed_size != 0) @@ -689,9 +689,9 @@ asn_enc_rval_t SEQUENCE_encode_der(asn_TYPE_descriptor_t *td, void *sptr, * Decode the XER (XML) data. */ asn_dec_rval_t SEQUENCE_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **struct_ptr, - const char *opt_mname, const void *buf_ptr, - size_t size) + asn_TYPE_descriptor_t *td, void **struct_ptr, + const char *opt_mname, const void *buf_ptr, + size_t size) { /* * Bring closer parts of structure description. @@ -766,14 +766,14 @@ asn_dec_rval_t SEQUENCE_decode_xer(asn_codec_ctx_t *opt_codec_ctx, /* Invoke the inner type decoder, m.b. multiple times */ tmprval = elm->type->xer_decoder(opt_codec_ctx, elm->type, - memb_ptr2, elm->name, - buf_ptr, size); + memb_ptr2, elm->name, + buf_ptr, size); XER_ADVANCE(tmprval.consumed); if (tmprval.code != RC_OK) RETURN(tmprval.code); ctx->phase = 1; /* Back to body processing */ ctx->step = ++edx; ASN_DEBUG("XER/SEQUENCE phase => %d, step => %d", - ctx->phase, ctx->step); + ctx->phase, ctx->step); /* Fall through */ } @@ -783,173 +783,173 @@ asn_dec_rval_t SEQUENCE_decode_xer(asn_codec_ctx_t *opt_codec_ctx, ch_size = xer_next_token(&ctx->context, buf_ptr, size, &ch_type); switch (ch_size) { - case -1: - RETURN(RC_FAIL); - case 0: - RETURN(RC_WMORE); - default: - switch (ch_type) - { - case PXER_COMMENT: /* Got XML comment */ - case PXER_TEXT: /* Ignore free-standing text */ - XER_ADVANCE(ch_size); /* Skip silently */ - continue; - case PXER_TAG: - break; /* Check the rest down there */ - } + case -1: + RETURN(RC_FAIL); + case 0: + RETURN(RC_WMORE); + default: + switch (ch_type) + { + case PXER_COMMENT: /* Got XML comment */ + case PXER_TEXT: /* Ignore free-standing text */ + XER_ADVANCE(ch_size); /* Skip silently */ + continue; + case PXER_TAG: + break; /* Check the rest down there */ + } } tcv = xer_check_tag(buf_ptr, ch_size, xml_tag); ASN_DEBUG("XER/SEQUENCE: tcv = %d, ph=%d [%s]", tcv, ctx->phase, - xml_tag); + xml_tag); /* Skip the extensions section */ if (ctx->phase == 3) { switch (xer_skip_unknown(tcv, &ctx->left)) { - case -1: - ctx->phase = 4; - RETURN(RC_FAIL); - case 0: - XER_ADVANCE(ch_size); - continue; - case 1: - XER_ADVANCE(ch_size); - ctx->phase = 1; - continue; - case 2: - ctx->phase = 1; - break; + case -1: + ctx->phase = 4; + RETURN(RC_FAIL); + case 0: + XER_ADVANCE(ch_size); + continue; + case 1: + XER_ADVANCE(ch_size); + ctx->phase = 1; + continue; + case 2: + ctx->phase = 1; + break; } } switch (tcv) { - case XCT_CLOSING: - if (ctx->phase == 0) break; - ctx->phase = 0; - /* Fall through */ - case XCT_BOTH: - if (ctx->phase == 0) - { - if (edx >= td->elements_count || - /* Explicit OPTIONAL specs reaches the end + case XCT_CLOSING: + if (ctx->phase == 0) break; + ctx->phase = 0; + /* Fall through */ + case XCT_BOTH: + if (ctx->phase == 0) + { + if (edx >= td->elements_count || + /* Explicit OPTIONAL specs reaches the end */ - (edx + elements[edx].optional == - td->elements_count) || - /* All extensions are optional */ - (IN_EXTENSION_GROUP(specs, edx) && - specs->ext_before > td->elements_count)) - { - XER_ADVANCE(ch_size); - ctx->phase = 4; /* Phase out */ - RETURN(RC_OK); - } - else - { - ASN_DEBUG( - "Premature end of XER SEQUENCE"); - RETURN(RC_FAIL); - } - } - /* Fall through */ - case XCT_OPENING: - if (ctx->phase == 0) - { - XER_ADVANCE(ch_size); - ctx->phase = 1; /* Processing body phase */ - continue; - } - /* Fall through */ - case XCT_UNKNOWN_OP: - case XCT_UNKNOWN_BO: + (edx + elements[edx].optional == + td->elements_count) || + /* All extensions are optional */ + (IN_EXTENSION_GROUP(specs, edx) && + specs->ext_before > td->elements_count)) + { + XER_ADVANCE(ch_size); + ctx->phase = 4; /* Phase out */ + RETURN(RC_OK); + } + else + { + ASN_DEBUG( + "Premature end of XER SEQUENCE"); + RETURN(RC_FAIL); + } + } + /* Fall through */ + case XCT_OPENING: + if (ctx->phase == 0) + { + XER_ADVANCE(ch_size); + ctx->phase = 1; /* Processing body phase */ + continue; + } + /* Fall through */ + case XCT_UNKNOWN_OP: + case XCT_UNKNOWN_BO: - ASN_DEBUG("XER/SEQUENCE: tcv=%d, ph=%d, edx=%d", tcv, - ctx->phase, edx); - if (ctx->phase != 1) - { - break; /* Really unexpected */ - } + ASN_DEBUG("XER/SEQUENCE: tcv=%d, ph=%d, edx=%d", tcv, + ctx->phase, edx); + if (ctx->phase != 1) + { + break; /* Really unexpected */ + } - if (edx < td->elements_count) - { - /* + if (edx < td->elements_count) + { + /* * Search which member corresponds to this tag. */ - edx_end = edx + elements[edx].optional + 1; - if (edx_end > td->elements_count) - edx_end = td->elements_count; - for (n = edx; n < edx_end; n++) - { - elm = &td->elements[n]; - tcv = xer_check_tag(buf_ptr, ch_size, - elm->name); - switch (tcv) - { - case XCT_BOTH: - case XCT_OPENING: - /* + edx_end = edx + elements[edx].optional + 1; + if (edx_end > td->elements_count) + edx_end = td->elements_count; + for (n = edx; n < edx_end; n++) + { + elm = &td->elements[n]; + tcv = xer_check_tag(buf_ptr, ch_size, + elm->name); + switch (tcv) + { + case XCT_BOTH: + case XCT_OPENING: + /* * Process this member. */ - ctx->step = edx = n; - ctx->phase = 2; - break; - case XCT_UNKNOWN_OP: - case XCT_UNKNOWN_BO: - continue; - default: - n = edx_end; - break; /* Phase out */ - } - break; - } - if (n != edx_end) continue; - } - else - { - ASN_DEBUG("Out of defined members: %d/%d", edx, - td->elements_count); - } + ctx->step = edx = n; + ctx->phase = 2; + break; + case XCT_UNKNOWN_OP: + case XCT_UNKNOWN_BO: + continue; + default: + n = edx_end; + break; /* Phase out */ + } + break; + } + if (n != edx_end) continue; + } + else + { + ASN_DEBUG("Out of defined members: %d/%d", edx, + td->elements_count); + } - /* It is expected extension */ - if (IN_EXTENSION_GROUP( - specs, edx + (edx < td->elements_count - ? elements[edx].optional - : 0))) - { - ASN_DEBUG("Got anticipated extension at %d", - edx); - /* + /* It is expected extension */ + if (IN_EXTENSION_GROUP( + specs, edx + (edx < td->elements_count + ? elements[edx].optional + : 0))) + { + ASN_DEBUG("Got anticipated extension at %d", + edx); + /* * Check for (XCT_BOTH or XCT_UNKNOWN_BO) * By using a mask. Only record a pure * tags. */ - if (tcv & XCT_CLOSING) - { - /* Found without body */ - } - else - { - ctx->left = 1; - ctx->phase = 3; /* Skip ...'s */ - } - XER_ADVANCE(ch_size); - continue; - } + if (tcv & XCT_CLOSING) + { + /* Found without body */ + } + else + { + ctx->left = 1; + ctx->phase = 3; /* Skip ...'s */ + } + XER_ADVANCE(ch_size); + continue; + } - /* Fall through */ - default: - break; + /* Fall through */ + default: + break; } ASN_DEBUG("Unexpected XML tag in SEQUENCE [%c%c%c%c%c%c]", - size > 0 ? ((const char *)buf_ptr)[0] : '.', - size > 1 ? ((const char *)buf_ptr)[1] : '.', - size > 2 ? ((const char *)buf_ptr)[2] : '.', - size > 3 ? ((const char *)buf_ptr)[3] : '.', - size > 4 ? ((const char *)buf_ptr)[4] : '.', - size > 5 ? ((const char *)buf_ptr)[5] : '.'); + size > 0 ? ((const char *)buf_ptr)[0] : '.', + size > 1 ? ((const char *)buf_ptr)[1] : '.', + size > 2 ? ((const char *)buf_ptr)[2] : '.', + size > 3 ? ((const char *)buf_ptr)[3] : '.', + size > 4 ? ((const char *)buf_ptr)[4] : '.', + size > 5 ? ((const char *)buf_ptr)[5] : '.'); break; } @@ -958,8 +958,8 @@ asn_dec_rval_t SEQUENCE_decode_xer(asn_codec_ctx_t *opt_codec_ctx, } asn_enc_rval_t SEQUENCE_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { asn_enc_rval_t er; int xcan = (flags & XER_F_CANONICAL); @@ -997,7 +997,7 @@ asn_enc_rval_t SEQUENCE_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, /* Print the member itself */ tmper = elm->type->xer_encoder(elm->type, memb_ptr, ilevel + 1, - flags, cb, app_key); + flags, cb, app_key); if (tmper.encoded == -1) return tmper; _ASN_CALLBACK3("", 1); @@ -1012,7 +1012,7 @@ cb_failed: } int SEQUENCE_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { int edx; int ret; @@ -1056,7 +1056,7 @@ int SEQUENCE_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, /* Print the member itself */ ret = elm->type->print_struct(elm->type, memb_ptr, ilevel + 1, cb, - app_key); + app_key); if (ret) return ret; } @@ -1097,14 +1097,14 @@ void SEQUENCE_free(asn_TYPE_descriptor_t *td, void *sptr, int contents_only) } int SEQUENCE_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { int edx; if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -1139,13 +1139,13 @@ int SEQUENCE_constraint(asn_TYPE_descriptor_t *td, const void *sptr, if (elm->memb_constraints) { int ret = elm->memb_constraints(elm->type, memb_ptr, - ctfailcb, app_key); + ctfailcb, app_key); if (ret) return ret; } else { int ret = elm->type->check_constraints(elm->type, memb_ptr, - ctfailcb, app_key); + ctfailcb, app_key); if (ret) return ret; /* * Cannot inherit it earlier: @@ -1159,9 +1159,9 @@ int SEQUENCE_constraint(asn_TYPE_descriptor_t *td, const void *sptr, } asn_dec_rval_t SEQUENCE_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd) { asn_SEQUENCE_specifics_t *specs = (asn_SEQUENCE_specifics_t *)td->specifics; void *st = *sptr; /* Target structure. */ @@ -1209,7 +1209,7 @@ asn_dec_rval_t SEQUENCE_decode_uper(asn_codec_ctx_t *opt_codec_ctx, opmd.buffer = opres; opmd.nbits = specs->roms_count; ASN_DEBUG("Read in presence bitmap for %s of %d bits (%x..)", - td->name, specs->roms_count, *opres); + td->name, specs->roms_count, *opres); } else { @@ -1243,8 +1243,8 @@ asn_dec_rval_t SEQUENCE_decode_uper(asn_codec_ctx_t *opt_codec_ctx, { int present = per_get_few_bits(&opmd, 1); ASN_DEBUG("Member %s->%s is optional, p=%d (%d->%d)", - td->name, elm->name, present, (int)opmd.nboff, - (int)opmd.nbits); + td->name, elm->name, present, (int)opmd.nboff, + (int)opmd.nbits); if (present == 0) { /* This element is not present */ @@ -1267,7 +1267,7 @@ asn_dec_rval_t SEQUENCE_decode_uper(asn_codec_ctx_t *opt_codec_ctx, /* Fetch the member from the stream */ ASN_DEBUG("Decoding member %s in %s", elm->name, td->name); rv = elm->type->uper_decoder(opt_codec_ctx, elm->type, - elm->per_constraints, memb_ptr2, pd); + elm->per_constraints, memb_ptr2, pd); if (rv.code != RC_OK) { ASN_DEBUG("Failed decode %s in %s", elm->name, td->name); @@ -1306,7 +1306,7 @@ asn_dec_rval_t SEQUENCE_decode_uper(asn_codec_ctx_t *opt_codec_ctx, epmd.buffer = epres; epmd.nbits = bmlength; ASN_DEBUG("Read in extensions bitmap for %s of %d bits (%x..)", - td->name, bmlength, *epres); + td->name, bmlength, *epres); /* Go over extensions and read them in */ for (edx = specs->ext_after + 1; edx < td->elements_count; edx++) @@ -1342,10 +1342,10 @@ asn_dec_rval_t SEQUENCE_decode_uper(asn_codec_ctx_t *opt_codec_ctx, } ASN_DEBUG("Decoding member %s in %s %p", elm->name, - td->name, *memb_ptr2); + td->name, *memb_ptr2); rv = uper_open_type_get(opt_codec_ctx, elm->type, - elm->per_constraints, memb_ptr2, pd); + elm->per_constraints, memb_ptr2, pd); if (rv.code != RC_OK) { FREEMEM(epres); @@ -1360,16 +1360,16 @@ asn_dec_rval_t SEQUENCE_decode_uper(asn_codec_ctx_t *opt_codec_ctx, ASN_DEBUG("Getting overflow extensions"); switch (per_get_few_bits(&epmd, 1)) { - case -1: - break; - case 0: - continue; - default: - if (uper_open_type_skip(opt_codec_ctx, pd)) - { - FREEMEM(epres); - _ASN_DECODE_STARVED; - } + case -1: + break; + case 0: + continue; + default: + if (uper_open_type_skip(opt_codec_ctx, pd)) + { + FREEMEM(epres); + _ASN_DECODE_STARVED; + } } break; } @@ -1410,7 +1410,7 @@ asn_dec_rval_t SEQUENCE_decode_uper(asn_codec_ctx_t *opt_codec_ctx, } static int SEQUENCE_handle_extensions(asn_TYPE_descriptor_t *td, void *sptr, - asn_per_outp_t *po1, asn_per_outp_t *po2) + asn_per_outp_t *po1, asn_per_outp_t *po2) { asn_SEQUENCE_specifics_t *specs = (asn_SEQUENCE_specifics_t *)td->specifics; int exts_present = 0; @@ -1430,7 +1430,7 @@ static int SEQUENCE_handle_extensions(asn_TYPE_descriptor_t *td, void *sptr, if (!IN_EXTENSION_GROUP(specs, edx)) { ASN_DEBUG("%s (@%d) is not extension", elm->type->name, - edx); + edx); continue; } @@ -1448,7 +1448,7 @@ static int SEQUENCE_handle_extensions(asn_TYPE_descriptor_t *td, void *sptr, } ASN_DEBUG("checking %s (@%d) present => %d", elm->type->name, edx, - present); + present); exts_count++; exts_present += present; @@ -1457,7 +1457,7 @@ static int SEQUENCE_handle_extensions(asn_TYPE_descriptor_t *td, void *sptr, /* Encode as open type field */ if (po2 && present && uper_open_type_put(elm->type, elm->per_constraints, *memb_ptr2, - po2)) + po2)) return -1; } @@ -1465,8 +1465,8 @@ static int SEQUENCE_handle_extensions(asn_TYPE_descriptor_t *td, void *sptr, } asn_enc_rval_t SEQUENCE_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *sptr, asn_per_outp_t *po) + asn_per_constraints_t *constraints, + void *sptr, asn_per_outp_t *po) { asn_SEQUENCE_specifics_t *specs = (asn_SEQUENCE_specifics_t *)td->specifics; asn_enc_rval_t er; @@ -1526,9 +1526,9 @@ asn_enc_rval_t SEQUENCE_encode_uper(asn_TYPE_descriptor_t *td, present = 0; ASN_DEBUG("Element %s %s %s->%s is %s", - elm->flags & ATF_POINTER ? "ptr" : "inline", - elm->default_value ? "def" : "wtv", td->name, elm->name, - present ? "present" : "absent"); + elm->flags & ATF_POINTER ? "ptr" : "inline", + elm->default_value ? "def" : "wtv", td->name, elm->name, + present ? "present" : "absent"); if (per_put_few_bits(po, present, 1)) _ASN_ENCODE_FAILED; } @@ -1536,7 +1536,7 @@ asn_enc_rval_t SEQUENCE_encode_uper(asn_TYPE_descriptor_t *td, * Encode the sequence ROOT elements. */ ASN_DEBUG("ext_after = %d, ec = %d, eb = %d", specs->ext_after, - td->elements_count, specs->ext_before); + td->elements_count, specs->ext_before); for (edx = 0; edx < ((specs->ext_after < 0) ? td->elements_count : specs->ext_before - 1); edx++) @@ -1556,7 +1556,7 @@ asn_enc_rval_t SEQUENCE_encode_uper(asn_TYPE_descriptor_t *td, if (!*memb_ptr2) { ASN_DEBUG("Element %s %d not present", elm->name, - edx); + edx); if (elm->optional) continue; /* Mandatory element is missing */ _ASN_ENCODE_FAILED; @@ -1574,7 +1574,7 @@ asn_enc_rval_t SEQUENCE_encode_uper(asn_TYPE_descriptor_t *td, ASN_DEBUG("Encoding %s->%s", td->name, elm->name); er = elm->type->uper_encoder(elm->type, elm->per_constraints, - *memb_ptr2, po); + *memb_ptr2, po); if (er.encoded == -1) return er; } diff --git a/src/core/libs/supl/asn-supl/constr_SEQUENCE_OF.c b/src/core/libs/supl/asn-supl/constr_SEQUENCE_OF.c index 00e6a2a4a..afdfa64a2 100644 --- a/src/core/libs/supl/asn-supl/constr_SEQUENCE_OF.c +++ b/src/core/libs/supl/asn-supl/constr_SEQUENCE_OF.c @@ -3,17 +3,17 @@ * All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ +#include #include #include -#include /* * The DER encoder of the SEQUENCE OF type. */ asn_enc_rval_t SEQUENCE_OF_encode_der(asn_TYPE_descriptor_t *td, void *ptr, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, - void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, + void *app_key) { asn_TYPE_member_t *elm = td->elements; asn_anonymous_sequence_ *list = _A_SEQUENCE_FROM_VOID(ptr); @@ -67,7 +67,7 @@ asn_enc_rval_t SEQUENCE_OF_encode_der(asn_TYPE_descriptor_t *td, void *ptr, void *memb_ptr = list->array[edx]; if (!memb_ptr) continue; erval = elm->type->der_encoder(elm->type, memb_ptr, 0, elm->tag, cb, - app_key); + app_key); if (erval.encoded == -1) return erval; encoding_size += erval.encoded; } @@ -92,10 +92,10 @@ asn_enc_rval_t SEQUENCE_OF_encode_der(asn_TYPE_descriptor_t *td, void *ptr, } asn_enc_rval_t SEQUENCE_OF_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, - int ilevel, - enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, - void *app_key) + int ilevel, + enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, + void *app_key) { asn_enc_rval_t er; asn_SET_OF_specifics_t *specs = (asn_SET_OF_specifics_t *)td->specifics; @@ -125,7 +125,7 @@ asn_enc_rval_t SEQUENCE_OF_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, } tmper = elm->type->xer_encoder(elm->type, memb_ptr, ilevel + 1, - flags, cb, app_key); + flags, cb, app_key); if (tmper.encoded == -1) return tmper; if (tmper.encoded == 0 && specs->as_XMLValueList) { @@ -152,8 +152,8 @@ cb_failed: } asn_enc_rval_t SEQUENCE_OF_encode_uper(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *sptr, asn_per_outp_t *po) + asn_per_constraints_t *constraints, + void *sptr, asn_per_outp_t *po) { asn_anonymous_sequence_ *list; asn_per_constraint_t *ct; @@ -181,7 +181,7 @@ asn_enc_rval_t SEQUENCE_OF_encode_uper(asn_TYPE_descriptor_t *td, int not_in_root = (list->count < ct->lower_bound || list->count > ct->upper_bound); ASN_DEBUG("lb %ld ub %ld %s", ct->lower_bound, ct->upper_bound, - ct->flags & APC_EXTENSIBLE ? "ext" : "fix"); + ct->flags & APC_EXTENSIBLE ? "ext" : "fix"); if (ct->flags & APC_EXTENSIBLE) { /* Declare whether size is in extension root */ @@ -197,7 +197,7 @@ asn_enc_rval_t SEQUENCE_OF_encode_uper(asn_TYPE_descriptor_t *td, { /* X.691, #19.5: No length determinant */ if (per_put_few_bits(po, list->count - ct->lower_bound, - ct->effective_bits)) + ct->effective_bits)) _ASN_ENCODE_FAILED; } diff --git a/src/core/libs/supl/asn-supl/constr_SET_OF.c b/src/core/libs/supl/asn-supl/constr_SET_OF.c index 3b62e9e64..25638af5d 100644 --- a/src/core/libs/supl/asn-supl/constr_SET_OF.c +++ b/src/core/libs/supl/asn-supl/constr_SET_OF.c @@ -3,9 +3,9 @@ * All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ +#include #include #include -#include /* * Number of bytes left for this structure. @@ -79,8 +79,8 @@ * The decoder of the SET OF type. */ asn_dec_rval_t SET_OF_decode_ber(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **struct_ptr, - const void *ptr, size_t size, int tag_mode) + asn_TYPE_descriptor_t *td, void **struct_ptr, + const void *ptr, size_t size, int tag_mode) { /* * Bring closer parts of structure description. @@ -123,191 +123,191 @@ asn_dec_rval_t SET_OF_decode_ber(asn_codec_ctx_t *opt_codec_ctx, */ switch (ctx->phase) { - case 0: - /* + case 0: + /* * PHASE 0. * Check that the set of tags associated with given structure * perfectly fits our expectations. */ - rval = ber_check_tags(opt_codec_ctx, td, ctx, ptr, size, - tag_mode, 1, &ctx->left, 0); - if (rval.code != RC_OK) - { - ASN_DEBUG("%s tagging check failed: %d", td->name, - rval.code); - return rval; - } + rval = ber_check_tags(opt_codec_ctx, td, ctx, ptr, size, + tag_mode, 1, &ctx->left, 0); + if (rval.code != RC_OK) + { + ASN_DEBUG("%s tagging check failed: %d", td->name, + rval.code); + return rval; + } - if (ctx->left >= 0) - ctx->left += rval.consumed; /* ?Subtracted below! */ - ADVANCE(rval.consumed); + if (ctx->left >= 0) + ctx->left += rval.consumed; /* ?Subtracted below! */ + ADVANCE(rval.consumed); - ASN_DEBUG( - "Structure consumes %ld bytes, " - "buffer %ld", - (long)ctx->left, (long)size); + ASN_DEBUG( + "Structure consumes %ld bytes, " + "buffer %ld", + (long)ctx->left, (long)size); - NEXT_PHASE(ctx); - /* Fall through */ - case 1: - /* + NEXT_PHASE(ctx); + /* Fall through */ + case 1: + /* * PHASE 1. * From the place where we've left it previously, * try to decode the next item. */ - for (;; ctx->step = 0) - { - ssize_t tag_len; /* Length of TLV's T */ + for (;; ctx->step = 0) + { + ssize_t tag_len; /* Length of TLV's T */ - if (ctx->step & 1) goto microphase2; + if (ctx->step & 1) goto microphase2; - /* + /* * MICROPHASE 1: Synchronize decoding. */ - if (ctx->left == 0) - { - ASN_DEBUG("End of SET OF %s", td->name); - /* + if (ctx->left == 0) + { + ASN_DEBUG("End of SET OF %s", td->name); + /* * No more things to decode. * Exit out of here. */ - PHASE_OUT(ctx); - RETURN(RC_OK); - } + PHASE_OUT(ctx); + RETURN(RC_OK); + } - /* + /* * Fetch the T from TLV. */ - tag_len = ber_fetch_tag(ptr, LEFT, &tlv_tag); - switch (tag_len) - { - case 0: - if (!SIZE_VIOLATION) RETURN(RC_WMORE); - /* Fall through */ - case -1: - RETURN(RC_FAIL); - } + tag_len = ber_fetch_tag(ptr, LEFT, &tlv_tag); + switch (tag_len) + { + case 0: + if (!SIZE_VIOLATION) RETURN(RC_WMORE); + /* Fall through */ + case -1: + RETURN(RC_FAIL); + } - if (ctx->left < 0 && ((const uint8_t *)ptr)[0] == 0) - { - if (LEFT < 2) - { - if (SIZE_VIOLATION) - RETURN(RC_FAIL); - else - RETURN(RC_WMORE); - } - else if (((const uint8_t *)ptr)[1] == 0) - { - /* + if (ctx->left < 0 && ((const uint8_t *)ptr)[0] == 0) + { + if (LEFT < 2) + { + if (SIZE_VIOLATION) + RETURN(RC_FAIL); + else + RETURN(RC_WMORE); + } + else if (((const uint8_t *)ptr)[1] == 0) + { + /* * Found the terminator of the * indefinite length structure. */ - break; - } - } + break; + } + } - /* Outmost tag may be unknown and cannot be + /* Outmost tag may be unknown and cannot be * fetched/compared */ - if (elm->tag != (ber_tlv_tag_t)-1) - { - if (BER_TAGS_EQUAL(tlv_tag, elm->tag)) - { - /* + if (elm->tag != (ber_tlv_tag_t)-1) + { + if (BER_TAGS_EQUAL(tlv_tag, elm->tag)) + { + /* * The new list member of expected type * has arrived. */ - } - else - { - ASN_DEBUG( - "Unexpected tag %s fixed SET OF %s", - ber_tlv_tag_string(tlv_tag), - td->name); - ASN_DEBUG("%s SET OF has tag %s", - td->name, - ber_tlv_tag_string(elm->tag)); - RETURN(RC_FAIL); - } - } + } + else + { + ASN_DEBUG( + "Unexpected tag %s fixed SET OF %s", + ber_tlv_tag_string(tlv_tag), + td->name); + ASN_DEBUG("%s SET OF has tag %s", + td->name, + ber_tlv_tag_string(elm->tag)); + RETURN(RC_FAIL); + } + } - /* + /* * MICROPHASE 2: Invoke the member-specific decoder. */ - ctx->step |= 1; /* Confirm entering next microphase */ - microphase2: + ctx->step |= 1; /* Confirm entering next microphase */ + microphase2: - /* + /* * Invoke the member fetch routine according to member's * type */ - rval = elm->type->ber_decoder(opt_codec_ctx, elm->type, - &ctx->ptr, ptr, LEFT, 0); - ASN_DEBUG("In %s SET OF %s code %d consumed %d", - td->name, elm->type->name, rval.code, - (int)rval.consumed); - switch (rval.code) + rval = elm->type->ber_decoder(opt_codec_ctx, elm->type, + &ctx->ptr, ptr, LEFT, 0); + ASN_DEBUG("In %s SET OF %s code %d consumed %d", + td->name, elm->type->name, rval.code, + (int)rval.consumed); + switch (rval.code) + { + case RC_OK: { - case RC_OK: - { - asn_anonymous_set_ *list = - _A_SET_FROM_VOID(st); - if (ASN_SET_ADD(list, ctx->ptr) != 0) - RETURN(RC_FAIL); - else - ctx->ptr = 0; - } - break; - case RC_WMORE: /* More data expected */ - if (!SIZE_VIOLATION) - { - ADVANCE(rval.consumed); - RETURN(RC_WMORE); - } - /* Fall through */ - case RC_FAIL: /* Fatal error */ - ASN_STRUCT_FREE(*elm->type, ctx->ptr); - ctx->ptr = 0; + asn_anonymous_set_ *list = + _A_SET_FROM_VOID(st); + if (ASN_SET_ADD(list, ctx->ptr) != 0) RETURN(RC_FAIL); - } /* switch(rval) */ + else + ctx->ptr = 0; + } + break; + case RC_WMORE: /* More data expected */ + if (!SIZE_VIOLATION) + { + ADVANCE(rval.consumed); + RETURN(RC_WMORE); + } + /* Fall through */ + case RC_FAIL: /* Fatal error */ + ASN_STRUCT_FREE(*elm->type, ctx->ptr); + ctx->ptr = 0; + RETURN(RC_FAIL); + } /* switch(rval) */ - ADVANCE(rval.consumed); - } /* for(all list members) */ + ADVANCE(rval.consumed); + } /* for(all list members) */ - NEXT_PHASE(ctx); - case 2: - /* + NEXT_PHASE(ctx); + case 2: + /* * Read in all "end of content" TLVs. */ - while (ctx->left < 0) - { - if (LEFT < 2) - { - if (LEFT > 0 && ((const char *)ptr)[0] != 0) - { - /* Unexpected tag */ - RETURN(RC_FAIL); - } - else - { - RETURN(RC_WMORE); - } - } - if (((const char *)ptr)[0] == 0 && - ((const char *)ptr)[1] == 0) - { - ADVANCE(2); - ctx->left++; - } - else - { - RETURN(RC_FAIL); - } - } + while (ctx->left < 0) + { + if (LEFT < 2) + { + if (LEFT > 0 && ((const char *)ptr)[0] != 0) + { + /* Unexpected tag */ + RETURN(RC_FAIL); + } + else + { + RETURN(RC_WMORE); + } + } + if (((const char *)ptr)[0] == 0 && + ((const char *)ptr)[1] == 0) + { + ADVANCE(2); + ctx->left++; + } + else + { + RETURN(RC_FAIL); + } + } - PHASE_OUT(ctx); + PHASE_OUT(ctx); } RETURN(RC_OK); @@ -362,8 +362,8 @@ static int _el_buf_cmp(const void *ap, const void *bp) * The DER encoder of the SET OF type. */ asn_enc_rval_t SET_OF_encode_der(asn_TYPE_descriptor_t *td, void *ptr, - int tag_mode, ber_tlv_tag_t tag, - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, ber_tlv_tag_t tag, + asn_app_consume_bytes_f *cb, void *app_key) { asn_TYPE_member_t *elm = td->elements; asn_TYPE_descriptor_t *elm_type = elm->type; @@ -466,7 +466,7 @@ asn_enc_rval_t SET_OF_encode_der(asn_TYPE_descriptor_t *td, void *ptr, * Encode the member into the prepared space. */ erval = der_encoder(elm_type, memb_ptr, 0, elm->tag, _el_addbytes, - encoded_el); + encoded_el); if (erval.encoded == -1) { for (; edx >= 0; edx--) FREEMEM(encoded_els[edx].buf); @@ -531,9 +531,9 @@ asn_enc_rval_t SET_OF_encode_der(asn_TYPE_descriptor_t *td, void *ptr, * Decode the XER (XML) data. */ asn_dec_rval_t SET_OF_decode_xer(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **struct_ptr, - const char *opt_mname, const void *buf_ptr, - size_t size) + asn_TYPE_descriptor_t *td, void **struct_ptr, + const char *opt_mname, const void *buf_ptr, + size_t size) { /* * Bring closer parts of structure description. @@ -624,63 +624,63 @@ asn_dec_rval_t SET_OF_decode_xer(asn_codec_ctx_t *opt_codec_ctx, ch_size = xer_next_token(&ctx->context, buf_ptr, size, &ch_type); switch (ch_size) { - case -1: - RETURN(RC_FAIL); - case 0: - RETURN(RC_WMORE); - default: - switch (ch_type) - { - case PXER_COMMENT: /* Got XML comment */ - case PXER_TEXT: /* Ignore free-standing text */ - XER_ADVANCE(ch_size); /* Skip silently */ - continue; - case PXER_TAG: - break; /* Check the rest down there */ - } + case -1: + RETURN(RC_FAIL); + case 0: + RETURN(RC_WMORE); + default: + switch (ch_type) + { + case PXER_COMMENT: /* Got XML comment */ + case PXER_TEXT: /* Ignore free-standing text */ + XER_ADVANCE(ch_size); /* Skip silently */ + continue; + case PXER_TAG: + break; /* Check the rest down there */ + } } tcv = xer_check_tag(buf_ptr, ch_size, xml_tag); ASN_DEBUG("XER/SET OF: tcv = %d, ph=%d t=%s", tcv, ctx->phase, - xml_tag); + xml_tag); switch (tcv) { - case XCT_CLOSING: - if (ctx->phase == 0) break; - ctx->phase = 0; - /* Fall through */ - case XCT_BOTH: - if (ctx->phase == 0) - { - /* No more things to decode */ - XER_ADVANCE(ch_size); - ctx->phase = 3; /* Phase out */ - RETURN(RC_OK); - } - /* Fall through */ - case XCT_OPENING: - if (ctx->phase == 0) - { - XER_ADVANCE(ch_size); - ctx->phase = 1; /* Processing body phase */ - continue; - } - /* Fall through */ - case XCT_UNKNOWN_OP: - case XCT_UNKNOWN_BO: + case XCT_CLOSING: + if (ctx->phase == 0) break; + ctx->phase = 0; + /* Fall through */ + case XCT_BOTH: + if (ctx->phase == 0) + { + /* No more things to decode */ + XER_ADVANCE(ch_size); + ctx->phase = 3; /* Phase out */ + RETURN(RC_OK); + } + /* Fall through */ + case XCT_OPENING: + if (ctx->phase == 0) + { + XER_ADVANCE(ch_size); + ctx->phase = 1; /* Processing body phase */ + continue; + } + /* Fall through */ + case XCT_UNKNOWN_OP: + case XCT_UNKNOWN_BO: - ASN_DEBUG("XER/SET OF: tcv=%d, ph=%d", tcv, ctx->phase); - if (ctx->phase == 1) - { - /* + ASN_DEBUG("XER/SET OF: tcv=%d, ph=%d", tcv, ctx->phase); + if (ctx->phase == 1) + { + /* * Process a single possible member. */ - ctx->phase = 2; - continue; - } - /* Fall through */ - default: - break; + ctx->phase = 2; + continue; + } + /* Fall through */ + default: + break; } ASN_DEBUG("Unexpected XML tag in SET OF"); @@ -698,7 +698,7 @@ typedef struct xer_tmp_enc_s size_t size; } xer_tmp_enc_t; static int SET_OF_encode_xer_callback(const void *buffer, size_t size, - void *key) + void *key) { xer_tmp_enc_t *t = (xer_tmp_enc_t *)key; if (t->offset + size >= t->size) @@ -729,8 +729,8 @@ static int SET_OF_xer_order(const void *aptr, const void *bptr) } asn_enc_rval_t SET_OF_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, - int ilevel, enum xer_encoder_flags_e flags, - asn_app_consume_bytes_f *cb, void *app_key) + int ilevel, enum xer_encoder_flags_e flags, + asn_app_consume_bytes_f *cb, void *app_key) { asn_enc_rval_t er; asn_SET_OF_specifics_t *specs = (asn_SET_OF_specifics_t *)td->specifics; @@ -846,7 +846,7 @@ cleanup: } int SET_OF_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { asn_TYPE_member_t *elm = td->elements; const asn_anonymous_set_ *list = _A_CSET_FROM_VOID(sptr); @@ -868,7 +868,7 @@ int SET_OF_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, _i_INDENT(1); ret = elm->type->print_struct(elm->type, memb_ptr, ilevel + 1, cb, - app_key); + app_key); if (ret) return ret; } @@ -917,7 +917,7 @@ void SET_OF_free(asn_TYPE_descriptor_t *td, void *ptr, int contents_only) } int SET_OF_constraint(asn_TYPE_descriptor_t *td, const void *sptr, - asn_app_constraint_failed_f *ctfailcb, void *app_key) + asn_app_constraint_failed_f *ctfailcb, void *app_key) { asn_TYPE_member_t *elm = td->elements; asn_constr_check_f *constr; @@ -927,7 +927,7 @@ int SET_OF_constraint(asn_TYPE_descriptor_t *td, const void *sptr, if (!sptr) { _ASN_CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", - td->name, __FILE__, __LINE__); + td->name, __FILE__, __LINE__); return -1; } @@ -960,9 +960,9 @@ int SET_OF_constraint(asn_TYPE_descriptor_t *td, const void *sptr, } asn_dec_rval_t SET_OF_decode_uper(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd) { asn_dec_rval_t rv; asn_SET_OF_specifics_t *specs = (asn_SET_OF_specifics_t *)td->specifics; @@ -1005,7 +1005,7 @@ asn_dec_rval_t SET_OF_decode_uper(asn_codec_ctx_t *opt_codec_ctx, /* X.691, #19.5: No length determinant */ nelems = per_get_few_bits(pd, ct->effective_bits); ASN_DEBUG("Preparing to fetch %ld+%ld elements from %s", - (long)nelems, ct->lower_bound, td->name); + (long)nelems, ct->lower_bound, td->name); if (nelems < 0) _ASN_DECODE_STARVED; nelems += ct->lower_bound; } @@ -1019,9 +1019,9 @@ asn_dec_rval_t SET_OF_decode_uper(asn_codec_ctx_t *opt_codec_ctx, if (nelems < 0) { nelems = uper_get_length(pd, ct ? ct->effective_bits : -1, - &repeat); + &repeat); ASN_DEBUG("Got to decode %d elements (eff %d)", (int)nelems, - (long)ct ? ct->effective_bits : -1); + (long)ct ? ct->effective_bits : -1); if (nelems < 0) _ASN_DECODE_STARVED; } @@ -1031,21 +1031,21 @@ asn_dec_rval_t SET_OF_decode_uper(asn_codec_ctx_t *opt_codec_ctx, ASN_DEBUG("SET OF %s decoding", elm->type->name); rv = elm->type->uper_decoder(opt_codec_ctx, elm->type, - elm->per_constraints, &ptr, pd); + elm->per_constraints, &ptr, pd); ASN_DEBUG("%s SET OF %s decoded %d, %p", td->name, - elm->type->name, rv.code, ptr); + elm->type->name, rv.code, ptr); if (rv.code == RC_OK) { if (ASN_SET_ADD(list, ptr) == 0) continue; ASN_DEBUG("Failed to add element into %s", - td->name); + td->name); /* Fall through */ rv.code = RC_FAIL; } else { ASN_DEBUG("Failed decoding %s of %s (SET OF)", - elm->type->name, td->name); + elm->type->name, td->name); } if (ptr) ASN_STRUCT_FREE(*elm->type, ptr); return rv; diff --git a/src/core/libs/supl/asn-supl/constr_TYPE.c b/src/core/libs/supl/asn-supl/constr_TYPE.c index 05c70989d..0e0cf4bda 100644 --- a/src/core/libs/supl/asn-supl/constr_TYPE.c +++ b/src/core/libs/supl/asn-supl/constr_TYPE.c @@ -17,8 +17,8 @@ static asn_app_consume_bytes_f _print2fp; * Return the outmost tag of the type. */ ber_tlv_tag_t asn_TYPE_outmost_tag(asn_TYPE_descriptor_t *type_descriptor, - const void *struct_ptr, int tag_mode, - ber_tlv_tag_t tag) + const void *struct_ptr, int tag_mode, + ber_tlv_tag_t tag) { if (tag_mode) return tag; diff --git a/src/core/libs/supl/asn-supl/constr_TYPE.h b/src/core/libs/supl/asn-supl/constr_TYPE.h index 3af569530..92b9fd914 100644 --- a/src/core/libs/supl/asn-supl/constr_TYPE.h +++ b/src/core/libs/supl/asn-supl/constr_TYPE.h @@ -39,12 +39,12 @@ extern "C" } asn_struct_ctx_t; #include /* Basic Encoding Rules decoder */ +#include /* Subtype constraints support */ #include /* Distinguished Encoding Rules encoder */ -#include /* Decoder of XER (XML, text) */ -#include /* Encoder into XER (XML, text) */ #include /* Packet Encoding Rules decoder */ #include /* Packet Encoding Rules encoder */ -#include /* Subtype constraints support */ +#include /* Decoder of XER (XML, text) */ +#include /* Encoder into XER (XML, text) */ /* * Free the structure according to its specification. @@ -110,10 +110,10 @@ extern "C" * Tags that are expected to occur. */ asn_outmost_tag_f *outmost_tag; /* */ - ber_tlv_tag_t *tags; /* Effective tags sequence for this type */ - int tags_count; /* Number of tags which are expected */ - ber_tlv_tag_t *all_tags; /* Every tag for BER/containment */ - int all_tags_count; /* Number of tags */ + ber_tlv_tag_t *tags; /* Effective tags sequence for this type */ + int tags_count; /* Number of tags which are expected */ + ber_tlv_tag_t *all_tags; /* Every tag for BER/containment */ + int all_tags_count; /* Number of tags */ asn_per_constraints_t *per_constraints; /* PER compiled constraints */ @@ -142,16 +142,16 @@ extern "C" }; typedef struct asn_TYPE_member_s { - enum asn_TYPE_flags_e flags; /* Element's presentation flags */ - int optional; /* Following optional members, including current */ - int memb_offset; /* Offset of the element */ - ber_tlv_tag_t tag; /* Outmost (most immediate) tag */ - int tag_mode; /* IMPLICIT/no/EXPLICIT tag at current level */ - asn_TYPE_descriptor_t *type; /* Member type descriptor */ - asn_constr_check_f *memb_constraints; /* Constraints validator */ - asn_per_constraints_t *per_constraints; /* PER compiled constraints */ + enum asn_TYPE_flags_e flags; /* Element's presentation flags */ + int optional; /* Following optional members, including current */ + int memb_offset; /* Offset of the element */ + ber_tlv_tag_t tag; /* Outmost (most immediate) tag */ + int tag_mode; /* IMPLICIT/no/EXPLICIT tag at current level */ + asn_TYPE_descriptor_t *type; /* Member type descriptor */ + asn_constr_check_f *memb_constraints; /* Constraints validator */ + asn_per_constraints_t *per_constraints; /* PER compiled constraints */ int (*default_value)(int setval, void **sptr); /* DEFAULT */ - char *name; /* ASN.1 identifier of the element */ + char *name; /* ASN.1 identifier of the element */ } asn_TYPE_member_t; /* @@ -174,9 +174,9 @@ extern "C" * -1: Problem dumping the structure. * (See also xer_fprint() in xer_encoder.h) */ - int asn_fprint(FILE *stream, /* Destination stream descriptor */ - asn_TYPE_descriptor_t *td, /* ASN.1 type descriptor */ - const void *struct_ptr); /* Structure to be printed */ + int asn_fprint(FILE *stream, /* Destination stream descriptor */ + asn_TYPE_descriptor_t *td, /* ASN.1 type descriptor */ + const void *struct_ptr); /* Structure to be printed */ #ifdef __cplusplus } diff --git a/src/core/libs/supl/asn-supl/constraints.c b/src/core/libs/supl/asn-supl/constraints.c index ba03304f1..3d96897ac 100644 --- a/src/core/libs/supl/asn-supl/constraints.c +++ b/src/core/libs/supl/asn-supl/constraints.c @@ -1,9 +1,11 @@ +// clang-format off #include "asn_internal.h" #include "constraints.h" +// clang-format on int asn_generic_no_constraint(asn_TYPE_descriptor_t *type_descriptor, - const void *struct_ptr, - asn_app_constraint_failed_f *cb, void *key) + const void *struct_ptr, + asn_app_constraint_failed_f *cb, void *key) { (void)type_descriptor; /* Unused argument */ (void)struct_ptr; /* Unused argument */ @@ -15,8 +17,8 @@ int asn_generic_no_constraint(asn_TYPE_descriptor_t *type_descriptor, } int asn_generic_unknown_constraint(asn_TYPE_descriptor_t *type_descriptor, - const void *struct_ptr, - asn_app_constraint_failed_f *cb, void *key) + const void *struct_ptr, + asn_app_constraint_failed_f *cb, void *key) { (void)type_descriptor; /* Unused argument */ (void)struct_ptr; /* Unused argument */ @@ -36,7 +38,7 @@ struct errbufDesc }; static void _asn_i_ctfailcb(void *key, asn_TYPE_descriptor_t *td, - const void *sptr, const char *fmt, ...) + const void *sptr, const char *fmt, ...) { struct errbufDesc *arg = key; va_list ap; @@ -77,7 +79,7 @@ static void _asn_i_ctfailcb(void *key, asn_TYPE_descriptor_t *td, } int asn_check_constraints(asn_TYPE_descriptor_t *type_descriptor, - const void *struct_ptr, char *errbuf, size_t *errlen) + const void *struct_ptr, char *errbuf, size_t *errlen) { struct errbufDesc arg; int ret; @@ -88,7 +90,7 @@ int asn_check_constraints(asn_TYPE_descriptor_t *type_descriptor, arg.errlen = errlen ? *errlen : 0; ret = type_descriptor->check_constraints(type_descriptor, struct_ptr, - _asn_i_ctfailcb, &arg); + _asn_i_ctfailcb, &arg); if (ret == -1 && errlen) *errlen = arg.errlen; return ret; diff --git a/src/core/libs/supl/asn-supl/constraints.h b/src/core/libs/supl/asn-supl/constraints.h index 5d339e2ff..ec9e669c0 100644 --- a/src/core/libs/supl/asn-supl/constraints.h +++ b/src/core/libs/supl/asn-supl/constraints.h @@ -40,14 +40,14 @@ extern "C" typedef int(asn_constr_check_f)( struct asn_TYPE_descriptor_s *type_descriptor, const void *struct_ptr, asn_app_constraint_failed_f *optional_callback, /* Log the error */ - void *optional_app_key /* Opaque key passed to a callback */ + void *optional_app_key /* Opaque key passed to a callback */ ); /******************************* * INTERNALLY USEFUL FUNCTIONS * *******************************/ - asn_constr_check_f asn_generic_no_constraint; /* No constraint whatsoever */ + asn_constr_check_f asn_generic_no_constraint; /* No constraint whatsoever */ asn_constr_check_f asn_generic_unknown_constraint; /* Not fully supported */ /* diff --git a/src/core/libs/supl/asn-supl/der_encoder.c b/src/core/libs/supl/asn-supl/der_encoder.c index 5c6aeab10..b65475a4d 100644 --- a/src/core/libs/supl/asn-supl/der_encoder.c +++ b/src/core/libs/supl/asn-supl/der_encoder.c @@ -6,15 +6,15 @@ #include static ssize_t der_write_TL(ber_tlv_tag_t tag, ber_tlv_len_t len, - asn_app_consume_bytes_f *cb, void *app_key, - int constructed); + asn_app_consume_bytes_f *cb, void *app_key, + int constructed); /* * The DER encoder of any type. */ asn_enc_rval_t der_encode(asn_TYPE_descriptor_t *type_descriptor, - void *struct_ptr, - asn_app_consume_bytes_f *consume_bytes, void *app_key) + void *struct_ptr, + asn_app_consume_bytes_f *consume_bytes, void *app_key) { ASN_DEBUG("DER encoder invoked for %s", type_descriptor->name); @@ -52,8 +52,8 @@ static int encode_to_buffer_cb(const void *buffer, size_t size, void *key) * A variant of the der_encode() which encodes the data into the provided buffer */ asn_enc_rval_t der_encode_to_buffer(asn_TYPE_descriptor_t *type_descriptor, - void *struct_ptr, void *buffer, - size_t buffer_size) + void *struct_ptr, void *buffer, + size_t buffer_size) { enc_to_buf_arg arg; asn_enc_rval_t ec; @@ -76,9 +76,9 @@ asn_enc_rval_t der_encode_to_buffer(asn_TYPE_descriptor_t *type_descriptor, * Write out leading TL[v] sequence according to the type definition. */ ssize_t der_write_tags(asn_TYPE_descriptor_t *sd, size_t struct_length, - int tag_mode, int last_tag_form, - ber_tlv_tag_t tag, /* EXPLICIT or IMPLICIT tag */ - asn_app_consume_bytes_f *cb, void *app_key) + int tag_mode, int last_tag_form, + ber_tlv_tag_t tag, /* EXPLICIT or IMPLICIT tag */ + asn_app_consume_bytes_f *cb, void *app_key) { ber_tlv_tag_t *tags; /* Copy of tags stream */ int tags_count; /* Number of tags */ @@ -87,10 +87,10 @@ ssize_t der_write_tags(asn_TYPE_descriptor_t *sd, size_t struct_length, int i; ASN_DEBUG("Writing tags (%s, tm=%d, tc=%d, tag=%s, mtc=%d)", sd->name, - tag_mode, sd->tags_count, ber_tlv_tag_string(tag), - tag_mode - ? (sd->tags_count + 1 - ((tag_mode == -1) && sd->tags_count)) - : sd->tags_count); + tag_mode, sd->tags_count, ber_tlv_tag_string(tag), + tag_mode + ? (sd->tags_count + 1 - ((tag_mode == -1) && sd->tags_count)) + : sd->tags_count); if (tag_mode) { @@ -148,7 +148,7 @@ ssize_t der_write_tags(asn_TYPE_descriptor_t *sd, size_t struct_length, if (!cb) return overall_length - struct_length; ASN_DEBUG("%s %s TL sequence (%d elements)", cb ? "Encoding" : "Estimating", - sd->name, tags_count); + sd->name, tags_count); /* * Encode the TL sequence for real. @@ -169,8 +169,8 @@ ssize_t der_write_tags(asn_TYPE_descriptor_t *sd, size_t struct_length, } static ssize_t der_write_TL(ber_tlv_tag_t tag, ber_tlv_len_t len, - asn_app_consume_bytes_f *cb, void *app_key, - int constructed) + asn_app_consume_bytes_f *cb, void *app_key, + int constructed) { uint8_t buf[32]; size_t size = 0; @@ -184,7 +184,7 @@ static ssize_t der_write_TL(ber_tlv_tag_t tag, ber_tlv_len_t len, /* Serialize length (L from TLV) into possibly zero-length buffer */ tmp = der_tlv_length_serialize(len, buf + size, - buf_size ? buf_size - size : 0); + buf_size ? buf_size - size : 0); if (tmp == -1) return -1; size += tmp; diff --git a/src/core/libs/supl/asn-supl/der_encoder.h b/src/core/libs/supl/asn-supl/der_encoder.h index ce08a6ce4..a36802046 100644 --- a/src/core/libs/supl/asn-supl/der_encoder.h +++ b/src/core/libs/supl/asn-supl/der_encoder.h @@ -19,9 +19,9 @@ extern "C" * The ber_decode() function (ber_decoder.h) is an opposite of der_encode(). */ asn_enc_rval_t der_encode(struct asn_TYPE_descriptor_s *type_descriptor, - void *struct_ptr, /* Structure to be encoded */ - asn_app_consume_bytes_f *consume_bytes_cb, - void *app_key /* Arbitrary callback argument */ + void *struct_ptr, /* Structure to be encoded */ + asn_app_consume_bytes_f *consume_bytes_cb, + void *app_key /* Arbitrary callback argument */ ); /* A variant of der_encode() which encodes data into the pre-allocated @@ -42,7 +42,7 @@ extern "C" int tag_mode, /* {-1,0,1}: IMPLICIT, no, EXPLICIT */ ber_tlv_tag_t tag, asn_app_consume_bytes_f *consume_bytes_cb, /* Callback */ - void *app_key /* Arbitrary callback argument */ + void *app_key /* Arbitrary callback argument */ ); /******************************* @@ -53,12 +53,12 @@ extern "C" * Write out leading TL[v] sequence according to the type definition. */ ssize_t der_write_tags(struct asn_TYPE_descriptor_s *sd, - size_t struct_length, - int tag_mode, /* {-1,0,1}: IMPLICIT, no, EXPLICIT */ - int last_tag_form, /* {0,!0}: prim, constructed */ - ber_tlv_tag_t tag, - asn_app_consume_bytes_f *consume_bytes_cb, - void *app_key); + size_t struct_length, + int tag_mode, /* {-1,0,1}: IMPLICIT, no, EXPLICIT */ + int last_tag_form, /* {0,!0}: prim, constructed */ + ber_tlv_tag_t tag, + asn_app_consume_bytes_f *consume_bytes_cb, + void *app_key); #ifdef __cplusplus } diff --git a/src/core/libs/supl/asn-supl/per_decoder.c b/src/core/libs/supl/asn-supl/per_decoder.c index b5dd27229..cb9effce6 100644 --- a/src/core/libs/supl/asn-supl/per_decoder.c +++ b/src/core/libs/supl/asn-supl/per_decoder.c @@ -8,8 +8,8 @@ * multiple of 8 bytes. */ asn_dec_rval_t uper_decode_complete(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **sptr, - const void *buffer, size_t size) + asn_TYPE_descriptor_t *td, void **sptr, + const void *buffer, size_t size) { asn_dec_rval_t rval; @@ -48,9 +48,9 @@ asn_dec_rval_t uper_decode_complete(asn_codec_ctx_t *opt_codec_ctx, } asn_dec_rval_t uper_decode(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **sptr, - const void *buffer, size_t size, int skip_bits, - int unused_bits) + asn_TYPE_descriptor_t *td, void **sptr, + const void *buffer, size_t size, int skip_bits, + int unused_bits) { asn_codec_ctx_t s_codec_ctx; asn_dec_rval_t rval; @@ -98,7 +98,7 @@ asn_dec_rval_t uper_decode(asn_codec_ctx_t *opt_codec_ctx, rval.consumed = ((pd.buffer - (const uint8_t *)buffer) << 3) + pd.nboff - skip_bits; ASN_DEBUG("PER decoding consumed %d, counted %d", rval.consumed, - pd.moved); + pd.moved); assert(rval.consumed == pd.moved); } else diff --git a/src/core/libs/supl/asn-supl/per_decoder.h b/src/core/libs/supl/asn-supl/per_decoder.h index 13f7acea1..f160473b9 100644 --- a/src/core/libs/supl/asn-supl/per_decoder.h +++ b/src/core/libs/supl/asn-supl/per_decoder.h @@ -23,9 +23,9 @@ extern "C" asn_dec_rval_t uper_decode_complete( struct asn_codec_ctx_s *opt_codec_ctx, struct asn_TYPE_descriptor_s *td, /* Type to decode */ - void **sptr, /* Pointer to a target structure's pointer */ - const void *buffer, /* Data to be decoded */ - size_t size /* Size of data buffer */ + void **sptr, /* Pointer to a target structure's pointer */ + const void *buffer, /* Data to be decoded */ + size_t size /* Size of data buffer */ ); /* @@ -36,11 +36,11 @@ extern "C" asn_dec_rval_t uper_decode( struct asn_codec_ctx_s *opt_codec_ctx, struct asn_TYPE_descriptor_s *td, /* Type to decode */ - void **sptr, /* Pointer to a target structure's pointer */ - const void *buffer, /* Data to be decoded */ - size_t size, /* Size of data buffer */ - int skip_bits, /* Number of unused leading bits, 0..7 */ - int unused_bits /* Number of unused tailing bits, 0..7 */ + void **sptr, /* Pointer to a target structure's pointer */ + const void *buffer, /* Data to be decoded */ + size_t size, /* Size of data buffer */ + int skip_bits, /* Number of unused leading bits, 0..7 */ + int unused_bits /* Number of unused tailing bits, 0..7 */ ); /* diff --git a/src/core/libs/supl/asn-supl/per_encoder.c b/src/core/libs/supl/asn-supl/per_encoder.c index af7678a8b..b0013b1ff 100644 --- a/src/core/libs/supl/asn-supl/per_encoder.c +++ b/src/core/libs/supl/asn-supl/per_encoder.c @@ -7,7 +7,7 @@ static asn_enc_rval_t uper_encode_internal( void *sptr, asn_app_consume_bytes_f *cb, void *app_key); asn_enc_rval_t uper_encode(asn_TYPE_descriptor_t *td, void *sptr, - asn_app_consume_bytes_f *cb, void *app_key) + asn_app_consume_bytes_f *cb, void *app_key) { return uper_encode_internal(td, 0, sptr, cb, app_key); } @@ -35,7 +35,7 @@ static int encode_to_buffer_cb(const void *buffer, size_t size, void *key) } asn_enc_rval_t uper_encode_to_buffer(asn_TYPE_descriptor_t *td, void *sptr, - void *buffer, size_t buffer_size) + void *buffer, size_t buffer_size) { enc_to_buf_arg key; @@ -74,8 +74,8 @@ static int encode_dyn_cb(const void *buffer, size_t size, void *key) return 0; } ssize_t uper_encode_to_new_buffer(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *sptr, void **buffer_r) + asn_per_constraints_t *constraints, + void *sptr, void **buffer_r) { asn_enc_rval_t er; enc_dyn_arg key; @@ -85,26 +85,26 @@ ssize_t uper_encode_to_new_buffer(asn_TYPE_descriptor_t *td, er = uper_encode_internal(td, constraints, sptr, encode_dyn_cb, &key); switch (er.encoded) { - case -1: - FREEMEM(key.buffer); - return -1; - case 0: - FREEMEM(key.buffer); - key.buffer = MALLOC(1); - if (key.buffer) - { - *(char *)key.buffer = '\0'; - *buffer_r = key.buffer; - return 1; - } - else - { - return -1; - } - default: - *buffer_r = key.buffer; - ASN_DEBUG("Complete encoded in %d bits", er.encoded); - return ((er.encoded + 7) >> 3); + case -1: + FREEMEM(key.buffer); + return -1; + case 0: + FREEMEM(key.buffer); + key.buffer = MALLOC(1); + if (key.buffer) + { + *(char *)key.buffer = '\0'; + *buffer_r = key.buffer; + return 1; + } + else + { + return -1; + } + default: + *buffer_r = key.buffer; + ASN_DEBUG("Complete encoded in %d bits", er.encoded); + return ((er.encoded + 7) >> 3); } } @@ -131,10 +131,10 @@ static int _uper_encode_flush_outp(asn_per_outp_t *po) } static asn_enc_rval_t uper_encode_internal(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void *sptr, - asn_app_consume_bytes_f *cb, - void *app_key) + asn_per_constraints_t *constraints, + void *sptr, + asn_app_consume_bytes_f *cb, + void *app_key) { asn_per_outp_t po; asn_enc_rval_t er; diff --git a/src/core/libs/supl/asn-supl/per_encoder.h b/src/core/libs/supl/asn-supl/per_encoder.h index e7fe7072a..822b8eae6 100644 --- a/src/core/libs/supl/asn-supl/per_encoder.h +++ b/src/core/libs/supl/asn-supl/per_encoder.h @@ -25,7 +25,7 @@ extern "C" struct asn_TYPE_descriptor_s *td, void *sptr, /* Structure to be encoded */ asn_app_consume_bytes_f *consume_bytes_cb, /* Data collector */ - void *app_key /* Arbitrary callback argument */ + void *app_key /* Arbitrary callback argument */ ); /* diff --git a/src/core/libs/supl/asn-supl/per_opentype.c b/src/core/libs/supl/asn-supl/per_opentype.c index 5a2921406..5a91e77ae 100644 --- a/src/core/libs/supl/asn-supl/per_opentype.c +++ b/src/core/libs/supl/asn-supl/per_opentype.c @@ -3,9 +3,9 @@ * Redistribution and modifications are permitted subject to BSD license. */ #include -#include #include #include +#include typedef struct uper_ugot_key { @@ -18,9 +18,9 @@ typedef struct uper_ugot_key static int uper_ugot_refill(asn_per_data_t *pd); static int per_skip_bits(asn_per_data_t *pd, int skip_nbits); static asn_dec_rval_t uper_sot_suck(asn_codec_ctx_t * /*ctx*/, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd); + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd); int asn_debug_indent; @@ -29,8 +29,8 @@ int asn_debug_indent; * #10.1, #10.2 */ int uper_open_type_put(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, void *sptr, - asn_per_outp_t *po) + asn_per_constraints_t *constraints, void *sptr, + asn_per_outp_t *po) { void *buf; void *bptr; @@ -55,7 +55,7 @@ int uper_open_type_put(asn_TYPE_descriptor_t *td, if (toGo) return -1; ASN_DEBUG("Open type put %s of length %d + overhead (1byte?)", td->name, - size); + size); return 0; } @@ -190,8 +190,8 @@ static asn_dec_rval_t GCC_NOTUSED uper_open_type_get_complex( } ASN_DEBUG("OpenType %s pd%s old%s unclaimed=%d, repeat=%d", td->name, - per_data_string(pd), per_data_string(&arg.oldpd), arg.unclaimed, - arg.repeat); + per_data_string(pd), per_data_string(&arg.oldpd), arg.unclaimed, + arg.repeat); padding = pd->moved % 8; if (padding) @@ -209,23 +209,23 @@ static asn_dec_rval_t GCC_NOTUSED uper_open_type_get_complex( pvalue = per_get_few_bits(pd, padding); switch (pvalue) { - case -1: - ASN_DEBUG("Padding skip failed"); - UPDRESTOREPD; - _ASN_DECODE_STARVED; - case 0: - break; - default: - ASN_DEBUG("Non-blank padding (%d bits 0x%02x)", padding, - (int)pvalue); - UPDRESTOREPD; - _ASN_DECODE_FAILED; + case -1: + ASN_DEBUG("Padding skip failed"); + UPDRESTOREPD; + _ASN_DECODE_STARVED; + case 0: + break; + default: + ASN_DEBUG("Non-blank padding (%d bits 0x%02x)", padding, + (int)pvalue); + UPDRESTOREPD; + _ASN_DECODE_FAILED; } } if (pd->nboff != pd->nbits) { ASN_DEBUG("Open type %s overhead pd%s old%s", td->name, - per_data_string(pd), per_data_string(&arg.oldpd)); + per_data_string(pd), per_data_string(&arg.oldpd)); if (1) { UPDRESTOREPD; @@ -246,16 +246,16 @@ static asn_dec_rval_t GCC_NOTUSED uper_open_type_get_complex( { switch (per_skip_bits(pd, arg.unclaimed)) { - case -1: - ASN_DEBUG("Claim of %d failed", arg.unclaimed); - _ASN_DECODE_STARVED; - case 0: - ASN_DEBUG("Got claim of %d", arg.unclaimed); - break; - default: - /* Padding must be blank */ - ASN_DEBUG("Non-blank unconsumed padding"); - _ASN_DECODE_FAILED; + case -1: + ASN_DEBUG("Claim of %d failed", arg.unclaimed); + _ASN_DECODE_STARVED; + case 0: + ASN_DEBUG("Got claim of %d", arg.unclaimed); + break; + default: + /* Padding must be blank */ + ASN_DEBUG("Non-blank unconsumed padding"); + _ASN_DECODE_FAILED; } arg.unclaimed = 0; } @@ -271,9 +271,9 @@ static asn_dec_rval_t GCC_NOTUSED uper_open_type_get_complex( } asn_dec_rval_t uper_open_type_get(asn_codec_ctx_t *ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd) { return uper_open_type_get_simple(ctx, td, constraints, sptr, pd); } @@ -298,9 +298,9 @@ int uper_open_type_skip(asn_codec_ctx_t *ctx, asn_per_data_t *pd) */ static asn_dec_rval_t uper_sot_suck(asn_codec_ctx_t *ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd) + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd) { asn_dec_rval_t rv; @@ -328,7 +328,7 @@ static int uper_ugot_refill(asn_per_data_t *pd) asn_per_data_t *oldpd = &arg->oldpd; ASN_DEBUG("REFILLING pd->moved=%d, oldpd->moved=%d", pd->moved, - oldpd->moved); + oldpd->moved); /* Advance our position to where pd is */ oldpd->buffer = pd->buffer; @@ -361,7 +361,7 @@ static int uper_ugot_refill(asn_per_data_t *pd) next_chunk_bytes = uper_get_length(oldpd, -1, &arg->repeat); ASN_DEBUG("Open type LENGTH %d bytes at off %d, repeat %d", - next_chunk_bytes, oldpd->moved, arg->repeat); + next_chunk_bytes, oldpd->moved, arg->repeat); if (next_chunk_bytes < 0) return -1; if (next_chunk_bytes == 0) { @@ -375,20 +375,20 @@ static int uper_ugot_refill(asn_per_data_t *pd) pd->nbits = oldpd->nboff + next_chunk_bits; arg->unclaimed = 0; ASN_DEBUG("!+Parent frame %d bits, alloting %d [%d..%d] (%d)", - next_chunk_bits, oldpd->moved, oldpd->nboff, oldpd->nbits, - oldpd->nbits - oldpd->nboff); + next_chunk_bits, oldpd->moved, oldpd->nboff, oldpd->nbits, + oldpd->nbits - oldpd->nboff); } else { pd->nbits = oldpd->nbits; arg->unclaimed = next_chunk_bits - avail; ASN_DEBUG("!-Parent frame %d, require %d, will claim %d", avail, - next_chunk_bits, arg->unclaimed); + next_chunk_bits, arg->unclaimed); } pd->buffer = oldpd->buffer; pd->nboff = oldpd->nboff; ASN_DEBUG("Refilled pd%s old%s", per_data_string(pd), - per_data_string(oldpd)); + per_data_string(oldpd)); return 0; } @@ -406,13 +406,13 @@ static int per_skip_bits(asn_per_data_t *pd, int skip_nbits) switch (per_get_few_bits(pd, skip)) { - case -1: - return -1; /* Starving */ - case 0: - continue; /* Skipped empty space */ - default: - hasNonZeroBits = 1; - continue; + case -1: + return -1; /* Starving */ + case 0: + continue; /* Skipped empty space */ + default: + hasNonZeroBits = 1; + continue; } } return hasNonZeroBits; diff --git a/src/core/libs/supl/asn-supl/per_opentype.h b/src/core/libs/supl/asn-supl/per_opentype.h index 1d1a7befa..a41ce9e15 100644 --- a/src/core/libs/supl/asn-supl/per_opentype.h +++ b/src/core/libs/supl/asn-supl/per_opentype.h @@ -11,15 +11,15 @@ extern "C" #endif asn_dec_rval_t uper_open_type_get(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, - void **sptr, asn_per_data_t *pd); + asn_TYPE_descriptor_t *td, + asn_per_constraints_t *constraints, + void **sptr, asn_per_data_t *pd); int uper_open_type_skip(asn_codec_ctx_t *opt_codec_ctx, asn_per_data_t *pd); int uper_open_type_put(asn_TYPE_descriptor_t *td, - asn_per_constraints_t *constraints, void *sptr, - asn_per_outp_t *po); + asn_per_constraints_t *constraints, void *sptr, + asn_per_outp_t *po); #ifdef __cplusplus } diff --git a/src/core/libs/supl/asn-supl/per_support.c b/src/core/libs/supl/asn-supl/per_support.c index 936ac77cd..9fdc23629 100644 --- a/src/core/libs/supl/asn-supl/per_support.c +++ b/src/core/libs/supl/asn-supl/per_support.c @@ -3,8 +3,8 @@ * All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ -#include #include +#include #include char *per_data_string(asn_per_data_t *pd) @@ -13,8 +13,8 @@ char *per_data_string(asn_per_data_t *pd) static int n; n = (n + 1) % 2; snprintf(buf[n], sizeof(buf[n]), "{m=%ld span %+ld[%d..%d] (%d)}", - (long)pd->moved, (((long)pd->buffer) & 0xf), (int)pd->nboff, - (int)pd->nbits, (int)(pd->nbits - pd->nboff)); + (long)pd->moved, (((long)pd->buffer) & 0xf), (int)pd->nboff, + (int)pd->nbits, (int)(pd->nbits - pd->nboff)); return buf[n]; } @@ -285,7 +285,7 @@ int uper_put_nsnnwn(asn_per_outp_t *po, int n) /* X.691-2008/11, #11.5.6 -> #11.3 */ int uper_get_constrained_whole_number(asn_per_data_t *pd, - unsigned long *out_value, int nbits) + unsigned long *out_value, int nbits) { unsigned long lhalf; /* Lower half of the number*/ long half; @@ -326,7 +326,7 @@ int uper_put_constrained_whole_number_s(asn_per_outp_t *po, long v, int nbits) } int uper_put_constrained_whole_number_u(asn_per_outp_t *po, unsigned long v, - int nbits) + int nbits) { if (nbits <= 31) { @@ -378,7 +378,7 @@ int per_put_few_bits(asn_per_outp_t *po, uint32_t bits, int obits) if (obits <= 0 || obits >= 32) return obits ? -1 : 0; ASN_DEBUG("[PER put %d bits %x to %p+%d bits]", obits, (int)bits, - po->buffer, (int)po->nboff); + po->buffer, (int)po->nboff); /* * Normalize position indicator. @@ -399,7 +399,7 @@ int per_put_few_bits(asn_per_outp_t *po, uint32_t bits, int obits) if (!po->buffer) po->buffer = po->tmpspace; complete_bytes = (po->buffer - po->tmpspace); ASN_DEBUG("[PER output %ld complete + %ld]", (long)complete_bytes, - (long)po->flushed_bytes); + (long)po->flushed_bytes); if (po->outper(po->tmpspace, complete_bytes, po->op_key) < 0) return -1; if (po->nboff) po->tmpspace[0] = po->buffer[0]; @@ -419,8 +419,8 @@ int per_put_few_bits(asn_per_outp_t *po, uint32_t bits, int obits) bits &= (((uint32_t)1 << obits) - 1); ASN_DEBUG("[PER out %d %u/%x (t=%d,o=%d) %x&%x=%x]", obits, (int)bits, - (int)bits, (int)po->nboff, (int)off, buf[0], (int)(omsk & 0xff), - (int)(buf[0] & omsk)); + (int)bits, (int)po->nboff, (int)off, buf[0], (int)(omsk & 0xff), + (int)(buf[0] & omsk)); if (off <= 8) /* Completely within 1 byte */ po->nboff = off, bits <<= (8 - off), buf[0] = (buf[0] & omsk) | bits; @@ -446,7 +446,7 @@ int per_put_few_bits(asn_per_outp_t *po, uint32_t bits, int obits) } ASN_DEBUG("[PER out %u/%x => %02x buf+%ld]", (int)bits, (int)bits, buf[0], - (po->buffer - po->tmpspace)); + (po->buffer - po->tmpspace)); return 0; } diff --git a/src/core/libs/supl/asn-supl/per_support.h b/src/core/libs/supl/asn-supl/per_support.h index 764a7cc15..f21889719 100644 --- a/src/core/libs/supl/asn-supl/per_support.h +++ b/src/core/libs/supl/asn-supl/per_support.h @@ -46,7 +46,7 @@ extern "C" const uint8_t *buffer; /* Pointer to the octet stream */ size_t nboff; /* Bit offset to the meaningful bit */ size_t nbits; /* Number of bits in the stream */ - size_t moved; /* Number of bits moved through this bit stream */ + size_t moved; /* Number of bits moved through this bit stream */ int (*refill)(struct asn_per_data_s *); void *refill_key; } asn_per_data_t; @@ -67,7 +67,7 @@ extern "C" * extracted due to EOD or other conditions. */ int per_get_many_bits(asn_per_data_t *pd, uint8_t *dst, int alright, - int get_nbits); + int get_nbits); /* * Get the length "n" from the Unaligned PER stream. @@ -86,7 +86,7 @@ extern "C" /* X.691-2008/11, #11.5.6 */ int uper_get_constrained_whole_number(asn_per_data_t *pd, - unsigned long *out_value, int nbits); + unsigned long *out_value, int nbits); /* Non-thread-safe debugging function, don't use it */ char *per_data_string(asn_per_data_t *pd); @@ -110,7 +110,7 @@ extern "C" /* Output a large number of bits */ int per_put_many_bits(asn_per_outp_t *po, const uint8_t *src, - int put_nbits); + int put_nbits); /* * Flush whole bytes (0 or more) through (outper) member. @@ -121,9 +121,9 @@ extern "C" /* X.691-2008/11, #11.5 */ int uper_put_constrained_whole_number_s(asn_per_outp_t *po, long v, - int nbits); + int nbits); int uper_put_constrained_whole_number_u(asn_per_outp_t *po, unsigned long v, - int nbits); + int nbits); /* * Put the length "n" to the Unaligned PER stream. diff --git a/src/core/libs/supl/asn-supl/xer_decoder.c b/src/core/libs/supl/asn-supl/xer_decoder.c index c7bc688bc..a027b0d11 100644 --- a/src/core/libs/supl/asn-supl/xer_decoder.c +++ b/src/core/libs/supl/asn-supl/xer_decoder.c @@ -10,8 +10,8 @@ * Decode the XER encoding of a given type. */ asn_dec_rval_t xer_decode(asn_codec_ctx_t *opt_codec_ctx, - asn_TYPE_descriptor_t *td, void **struct_ptr, - const void *buffer, size_t size) + asn_TYPE_descriptor_t *td, void **struct_ptr, + const void *buffer, size_t size) { asn_codec_ctx_t s_codec_ctx; @@ -50,7 +50,7 @@ struct xer__cb_arg }; static int xer__token_cb(pxml_chunk_type_e type, const void *_chunk_data, - size_t _chunk_size, void *key) + size_t _chunk_size, void *key) { struct xer__cb_arg *arg = (struct xer__cb_arg *)key; arg->chunk_type = type; @@ -64,7 +64,7 @@ static int xer__token_cb(pxml_chunk_type_e type, const void *_chunk_data, * Fetch the next token from the XER/XML stream. */ ssize_t xer_next_token(int *stateContext, const void *buffer, size_t size, - pxer_chunk_type_e *ch_type) + pxer_chunk_type_e *ch_type) { struct xer__cb_arg arg; int new_stateContext = *stateContext; @@ -89,18 +89,18 @@ ssize_t xer_next_token(int *stateContext, const void *buffer, size_t size, */ switch (arg.chunk_type) { - case PXML_TEXT: - *ch_type = PXER_TEXT; - break; - case PXML_TAG: - return 0; /* Want more */ - case PXML_TAG_END: - *ch_type = PXER_TAG; - break; - case PXML_COMMENT: - case PXML_COMMENT_END: - *ch_type = PXER_COMMENT; - break; + case PXML_TEXT: + *ch_type = PXER_TEXT; + break; + case PXML_TAG: + return 0; /* Want more */ + case PXML_TAG_END: + *ch_type = PXER_TAG; + break; + case PXML_COMMENT: + case PXML_COMMENT_END: + *ch_type = PXER_COMMENT; + break; } *stateContext = new_stateContext; @@ -112,7 +112,7 @@ ssize_t xer_next_token(int *stateContext, const void *buffer, size_t size, #define RANGLE 0x3e /* '>' */ xer_check_tag_e xer_check_tag(const void *buf_ptr, int size, - const char *need_tag) + const char *need_tag) { const char *buf = (const char *)buf_ptr; const char *end; @@ -163,13 +163,13 @@ xer_check_tag_e xer_check_tag(const void *buf_ptr, int size, { switch (b) { - case 0x09: - case 0x0a: - case 0x0c: - case 0x0d: - case 0x20: - /* "": whitespace is normal */ - return ct; + case 0x09: + case 0x0a: + case 0x0c: + case 0x0d: + case 0x20: + /* "": whitespace is normal */ + return ct; } } return (xer_check_tag_e)(XCT__UNK__MASK | ct); @@ -208,7 +208,7 @@ xer_check_tag_e xer_check_tag(const void *buf_ptr, int size, { \ ssize_t converted_size = \ body_receiver(struct_key, chunk_buf, chunk_size, \ - (size_t)(chunk_size) < (size)); \ + (size_t)(chunk_size) < (size)); \ if (converted_size == -1) RETURN(RC_FAIL); \ if (converted_size == 0 && (size) == (size_t)(chunk_size)) \ RETURN(RC_WMORE); \ @@ -232,9 +232,9 @@ asn_dec_rval_t xer_decode_general( void *struct_key, const char *xml_tag, /* Expected XML tag */ const void *buf_ptr, size_t size, int (*opt_unexpected_tag_decoder)(void *struct_key, const void *chunk_buf, - size_t chunk_size), + size_t chunk_size), ssize_t (*body_receiver)(void *struct_key, const void *chunk_buf, - size_t chunk_size, int have_more)) + size_t chunk_size, int have_more)) { asn_dec_rval_t rval; ssize_t consumed_myself = 0; @@ -259,37 +259,37 @@ asn_dec_rval_t xer_decode_general( ch_size = xer_next_token(&ctx->context, buf_ptr, size, &ch_type); switch (ch_size) { - case -1: - RETURN(RC_FAIL); - case 0: - RETURN(RC_WMORE); - default: - switch (ch_type) - { - case PXER_COMMENT: /* Got XML comment */ - ADVANCE(ch_size); /* Skip silently */ - continue; - case PXER_TEXT: - if (ctx->phase == 0) - { - /* + case -1: + RETURN(RC_FAIL); + case 0: + RETURN(RC_WMORE); + default: + switch (ch_type) + { + case PXER_COMMENT: /* Got XML comment */ + ADVANCE(ch_size); /* Skip silently */ + continue; + case PXER_TEXT: + if (ctx->phase == 0) + { + /* * We have to ignore whitespace * here, but in order to be forward * compatible with EXTENDED-XER * (EMBED-VALUES, #25) any text is * just ignored here. */ - } - else - { - XER_GOT_BODY(buf_ptr, ch_size, - size); - } - ADVANCE(ch_size); - continue; - case PXER_TAG: - break; /* Check the rest down there */ - } + } + else + { + XER_GOT_BODY(buf_ptr, ch_size, + size); + } + ADVANCE(ch_size); + continue; + case PXER_TAG: + break; /* Check the rest down there */ + } } assert(ch_type == PXER_TAG && size); @@ -304,45 +304,45 @@ asn_dec_rval_t xer_decode_general( */ switch (tcv) { - case XCT_BOTH: - if (ctx->phase) break; - /* Finished decoding of an empty element */ - XER_GOT_EMPTY(); - ADVANCE(ch_size); - ctx->phase = 2; /* Phase out */ - RETURN(RC_OK); - case XCT_OPENING: - if (ctx->phase) break; - ADVANCE(ch_size); - ctx->phase = 1; /* Processing body phase */ - continue; - case XCT_CLOSING: - if (!ctx->phase) break; - ADVANCE(ch_size); - ctx->phase = 2; /* Phase out */ - RETURN(RC_OK); - case XCT_UNKNOWN_BO: - /* + case XCT_BOTH: + if (ctx->phase) break; + /* Finished decoding of an empty element */ + XER_GOT_EMPTY(); + ADVANCE(ch_size); + ctx->phase = 2; /* Phase out */ + RETURN(RC_OK); + case XCT_OPENING: + if (ctx->phase) break; + ADVANCE(ch_size); + ctx->phase = 1; /* Processing body phase */ + continue; + case XCT_CLOSING: + if (!ctx->phase) break; + ADVANCE(ch_size); + ctx->phase = 2; /* Phase out */ + RETURN(RC_OK); + case XCT_UNKNOWN_BO: + /* * Certain tags in the body may be expected. */ - if (opt_unexpected_tag_decoder && - opt_unexpected_tag_decoder(struct_key, buf_ptr, - ch_size) >= 0) - { - /* Tag's processed fine */ - ADVANCE(ch_size); - if (!ctx->phase) - { - /* We are not expecting + if (opt_unexpected_tag_decoder && + opt_unexpected_tag_decoder(struct_key, buf_ptr, + ch_size) >= 0) + { + /* Tag's processed fine */ + ADVANCE(ch_size); + if (!ctx->phase) + { + /* We are not expecting * the closing tag anymore. */ - ctx->phase = 2; /* Phase out */ - RETURN(RC_OK); - } - continue; - } - /* Fall through */ - default: - break; /* Unexpected tag */ + ctx->phase = 2; /* Phase out */ + RETURN(RC_OK); + } + continue; + } + /* Fall through */ + default: + break; /* Unexpected tag */ } ASN_DEBUG("Unexpected XML tag (expected \"%s\")", xml_tag); @@ -361,19 +361,19 @@ int xer_is_whitespace(const void *chunk_buf, size_t chunk_size) { switch (*p) { - /* X.693, #8.1.4 + /* X.693, #8.1.4 * HORISONTAL TAB (9) * LINE FEED (10) * CARRIAGE RETURN (13) * SPACE (32) */ - case 0x09: - case 0x0a: - case 0x0d: - case 0x20: - break; - default: - return 0; + case 0x09: + case 0x0a: + case 0x0d: + case 0x20: + break; + default: + return 0; } } return 1; /* All whitespace */ @@ -387,19 +387,19 @@ int xer_skip_unknown(xer_check_tag_e tcv, ber_tlv_len_t *depth) assert(*depth > 0); switch (tcv) { - case XCT_BOTH: - case XCT_UNKNOWN_BO: - /* These negate each other. */ - return 0; - case XCT_OPENING: - case XCT_UNKNOWN_OP: - ++(*depth); - return 0; - case XCT_CLOSING: - case XCT_UNKNOWN_CL: - if (--(*depth) == 0) return (tcv == XCT_CLOSING) ? 2 : 1; - return 0; - default: - return -1; + case XCT_BOTH: + case XCT_UNKNOWN_BO: + /* These negate each other. */ + return 0; + case XCT_OPENING: + case XCT_UNKNOWN_OP: + ++(*depth); + return 0; + case XCT_CLOSING: + case XCT_UNKNOWN_CL: + if (--(*depth) == 0) return (tcv == XCT_CLOSING) ? 2 : 1; + return 0; + default: + return -1; } } diff --git a/src/core/libs/supl/asn-supl/xer_decoder.h b/src/core/libs/supl/asn-supl/xer_decoder.h index eee9777e1..f34b5e6f9 100644 --- a/src/core/libs/supl/asn-supl/xer_decoder.h +++ b/src/core/libs/supl/asn-supl/xer_decoder.h @@ -50,10 +50,10 @@ extern "C" const char *xml_tag, /* Expected XML tag name */ const void *buf_ptr, size_t size, int (*opt_unexpected_tag_decoder)(void *struct_key, - const void *chunk_buf, - size_t chunk_size), + const void *chunk_buf, + size_t chunk_size), ssize_t (*body_receiver)(void *struct_key, const void *chunk_buf, - size_t chunk_size, int have_more)); + size_t chunk_size, int have_more)); /* * Fetch the next XER (XML) token from the stream. @@ -68,7 +68,7 @@ extern "C" PXER_COMMENT /* A comment, may be part of */ } pxer_chunk_type_e; ssize_t xer_next_token(int *stateContext, const void *buffer, size_t size, - pxer_chunk_type_e *_ch_type); + pxer_chunk_type_e *_ch_type); /* * This function checks the buffer against the tag name is expected to @@ -86,7 +86,7 @@ extern "C" XCT_UNKNOWN_BO = 7 /* Unexpected tag */ } xer_check_tag_e; xer_check_tag_e xer_check_tag(const void *buf_ptr, int size, - const char *need_tag); + const char *need_tag); /* * Check whether this buffer consists of entirely XER whitespace characters. diff --git a/src/core/libs/supl/asn-supl/xer_encoder.c b/src/core/libs/supl/asn-supl/xer_encoder.c index e723695ae..584fbac1a 100644 --- a/src/core/libs/supl/asn-supl/xer_encoder.c +++ b/src/core/libs/supl/asn-supl/xer_encoder.c @@ -3,15 +3,15 @@ * Redistribution and modifications are permitted subject to BSD license. */ #include -#include #include +#include /* * The XER encoder of any type. May be invoked by the application. */ asn_enc_rval_t xer_encode(asn_TYPE_descriptor_t *td, void *sptr, - enum xer_encoder_flags_e xer_flags, - asn_app_consume_bytes_f *cb, void *app_key) + enum xer_encoder_flags_e xer_flags, + asn_app_consume_bytes_f *cb, void *app_key) { asn_enc_rval_t er; asn_enc_rval_t tmper; diff --git a/src/core/libs/supl/asn-supl/xer_encoder.h b/src/core/libs/supl/asn-supl/xer_encoder.h index c6e9e6c38..80cac3561 100644 --- a/src/core/libs/supl/asn-supl/xer_encoder.h +++ b/src/core/libs/supl/asn-supl/xer_encoder.h @@ -27,10 +27,10 @@ extern "C" * The XER encoder of any type. May be invoked by the application. */ asn_enc_rval_t xer_encode(struct asn_TYPE_descriptor_s *td, - void *sptr, /* Structure to be encoded */ - enum xer_encoder_flags_e xer_flags, - asn_app_consume_bytes_f *consume_bytes_cb, - void *app_key /* Arbitrary callback argument */ + void *sptr, /* Structure to be encoded */ + enum xer_encoder_flags_e xer_flags, + asn_app_consume_bytes_f *consume_bytes_cb, + void *app_key /* Arbitrary callback argument */ ); /* @@ -52,7 +52,7 @@ extern "C" int ilevel, /* Level of indentation */ enum xer_encoder_flags_e xer_flags, asn_app_consume_bytes_f *consume_bytes_cb, /* Callback */ - void *app_key /* Arbitrary callback argument */ + void *app_key /* Arbitrary callback argument */ ); #ifdef __cplusplus diff --git a/src/core/libs/supl/asn-supl/xer_support.c b/src/core/libs/supl/asn-supl/xer_support.c index fca8b4fac..1edf24f11 100644 --- a/src/core/libs/supl/asn-supl/xer_support.c +++ b/src/core/libs/supl/asn-supl/xer_support.c @@ -24,7 +24,11 @@ typedef enum } pstate_e; static pxml_chunk_type_e final_chunk_type[] = { - PXML_TEXT, PXML_TAG_END, PXML_COMMENT_END, PXML_TAG_END, PXML_COMMENT_END, + PXML_TEXT, + PXML_TAG_END, + PXML_COMMENT_END, + PXML_TAG_END, + PXML_COMMENT_END, }; static int _charclass[256] = { @@ -32,10 +36,10 @@ static int _charclass[256] = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 0, 0, 0, 0, 0, 0, /* 01234567 89 */ - 0, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, /* ABCDEFG HIJKLMNO */ - 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0, /* PQRSTUVW XYZ */ - 0, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, /* abcdefg hijklmno */ - 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0 /* pqrstuvw xyz */ + 0, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, /* ABCDEFG HIJKLMNO */ + 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0, /* PQRSTUVW XYZ */ + 0, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, /* abcdefg hijklmno */ + 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 0, 0, 0, 0, 0 /* pqrstuvw xyz */ }; #define WHITESPACE(c) (_charclass[(unsigned char)(c)] == 1) #define ALNUM(c) (_charclass[(unsigned char)(c)] >= 2) @@ -85,7 +89,7 @@ static int _charclass[256] = { * Parser itself */ ssize_t pxml_parse(int *stateContext, const void *xmlbuf, size_t size, - pxml_callback_f *cb, void *key) + pxml_callback_f *cb, void *key) { pstate_e state = (pstate_e)*stateContext; const char *chunk_start = (const char *)xmlbuf; @@ -97,142 +101,142 @@ ssize_t pxml_parse(int *stateContext, const void *xmlbuf, size_t size, int C = *(const unsigned char *)p; switch (state) { - case ST_TEXT: - /* + case ST_TEXT: + /* * Initial state: we're in the middle of some text, * or just have started. */ - if (C == LANGLE) /* We're now in the tag, probably */ - TOKEN_CB(PXML_TEXT, ST_TAG_START, 0); - break; - case ST_TAG_START: - if (ALPHA(C) || (C == CSLASH)) - state = ST_TAG_BODY; - else if (C == EXCLAM) - state = ST_COMMENT_WAIT_DASH1; - else - /* + if (C == LANGLE) /* We're now in the tag, probably */ + TOKEN_CB(PXML_TEXT, ST_TAG_START, 0); + break; + case ST_TAG_START: + if (ALPHA(C) || (C == CSLASH)) + state = ST_TAG_BODY; + else if (C == EXCLAM) + state = ST_COMMENT_WAIT_DASH1; + else + /* * Not characters and not whitespace. * Must be something like "3 < 4". */ - TOKEN_CB(PXML_TEXT, ST_TEXT, 1); /* Flush as data */ - break; - case ST_TAG_BODY: - switch (C) - { - case RANGLE: - /* End of the tag */ - TOKEN_CB_FINAL(PXML_TAG, ST_TEXT, 1); - break; - case LANGLE: - /* + TOKEN_CB(PXML_TEXT, ST_TEXT, 1); /* Flush as data */ + break; + case ST_TAG_BODY: + switch (C) + { + case RANGLE: + /* End of the tag */ + TOKEN_CB_FINAL(PXML_TAG, ST_TEXT, 1); + break; + case LANGLE: + /* * The previous tag wasn't completed, but * still recognized as valid. * (Mozilla-compatible) */ - TOKEN_CB_FINAL(PXML_TAG, ST_TAG_START, 0); - break; - case CEQUAL: - state = ST_TAG_QUOTE_WAIT; - break; - } - break; - case ST_TAG_QUOTE_WAIT: - /* + TOKEN_CB_FINAL(PXML_TAG, ST_TAG_START, 0); + break; + case CEQUAL: + state = ST_TAG_QUOTE_WAIT; + break; + } + break; + case ST_TAG_QUOTE_WAIT: + /* * State after the equal sign ("=") in the tag. */ - switch (C) - { - case CQUOTE: - state = ST_TAG_QUOTED_STRING; - break; - case RANGLE: - /* End of the tag */ - TOKEN_CB_FINAL(PXML_TAG, ST_TEXT, 1); - break; - default: - if (!WHITESPACE( - C)) /* Unquoted string value */ - state = ST_TAG_UNQUOTED_STRING; - } - break; - case ST_TAG_QUOTED_STRING: - /* + switch (C) + { + case CQUOTE: + state = ST_TAG_QUOTED_STRING; + break; + case RANGLE: + /* End of the tag */ + TOKEN_CB_FINAL(PXML_TAG, ST_TEXT, 1); + break; + default: + if (!WHITESPACE( + C)) /* Unquoted string value */ + state = ST_TAG_UNQUOTED_STRING; + } + break; + case ST_TAG_QUOTED_STRING: + /* * Tag attribute's string value in quotes. */ - if (C == CQUOTE) - { - /* Return back to the tag state */ - state = ST_TAG_BODY; - } - break; - case ST_TAG_UNQUOTED_STRING: - if (C == RANGLE) - { - /* End of the tag */ - TOKEN_CB_FINAL(PXML_TAG, ST_TEXT, 1); - } - else if (WHITESPACE(C)) - { - /* Return back to the tag state */ - state = ST_TAG_BODY; - } - break; - case ST_COMMENT_WAIT_DASH1: - if (C == CDASH) - { - state = ST_COMMENT_WAIT_DASH2; - } - else - { - /* Some ordinary tag. */ - state = ST_TAG_BODY; - } - break; - case ST_COMMENT_WAIT_DASH2: - if (C == CDASH) - { - /* Seen "<--" */ - state = ST_COMMENT; - } - else - { - /* Some ordinary tag */ - state = ST_TAG_BODY; - } - break; - case ST_COMMENT: - if (C == CDASH) - { - state = ST_COMMENT_CLO_DASH2; - } - break; - case ST_COMMENT_CLO_DASH2: - if (C == CDASH) - { - state = ST_COMMENT_CLO_RT; - } - else - { - /* This is not an end of a comment */ - state = ST_COMMENT; - } - break; - case ST_COMMENT_CLO_RT: - if (C == RANGLE) - { - TOKEN_CB_FINAL(PXML_COMMENT, ST_TEXT, 1); - } - else if (C == CDASH) - { - /* Maintain current state, still waiting for '>' + if (C == CQUOTE) + { + /* Return back to the tag state */ + state = ST_TAG_BODY; + } + break; + case ST_TAG_UNQUOTED_STRING: + if (C == RANGLE) + { + /* End of the tag */ + TOKEN_CB_FINAL(PXML_TAG, ST_TEXT, 1); + } + else if (WHITESPACE(C)) + { + /* Return back to the tag state */ + state = ST_TAG_BODY; + } + break; + case ST_COMMENT_WAIT_DASH1: + if (C == CDASH) + { + state = ST_COMMENT_WAIT_DASH2; + } + else + { + /* Some ordinary tag. */ + state = ST_TAG_BODY; + } + break; + case ST_COMMENT_WAIT_DASH2: + if (C == CDASH) + { + /* Seen "<--" */ + state = ST_COMMENT; + } + else + { + /* Some ordinary tag */ + state = ST_TAG_BODY; + } + break; + case ST_COMMENT: + if (C == CDASH) + { + state = ST_COMMENT_CLO_DASH2; + } + break; + case ST_COMMENT_CLO_DASH2: + if (C == CDASH) + { + state = ST_COMMENT_CLO_RT; + } + else + { + /* This is not an end of a comment */ + state = ST_COMMENT; + } + break; + case ST_COMMENT_CLO_RT: + if (C == RANGLE) + { + TOKEN_CB_FINAL(PXML_COMMENT, ST_TEXT, 1); + } + else if (C == CDASH) + { + /* Maintain current state, still waiting for '>' */ - } - else - { - state = ST_COMMENT; - } - break; + } + else + { + state = ST_COMMENT; + } + break; } /* switch(*ptr) */ } /* for() */ @@ -243,14 +247,14 @@ ssize_t pxml_parse(int *stateContext, const void *xmlbuf, size_t size, { switch (state) { - case ST_COMMENT: - TOKEN_CB(PXML_COMMENT, state, 0); - break; - case ST_TEXT: - TOKEN_CB(PXML_TEXT, state, 0); - break; - default: - break; /* a no-op */ + case ST_COMMENT: + TOKEN_CB(PXML_COMMENT, state, 0); + break; + case ST_TEXT: + TOKEN_CB(PXML_TEXT, state, 0); + break; + default: + break; /* a no-op */ } } diff --git a/src/core/libs/supl/asn-supl/xer_support.h b/src/core/libs/supl/asn-supl/xer_support.h index af413aae4..eeec7291f 100644 --- a/src/core/libs/supl/asn-supl/xer_support.h +++ b/src/core/libs/supl/asn-supl/xer_support.h @@ -38,8 +38,8 @@ extern "C" * The chunk is NOT '\0'-terminated. */ typedef int(pxml_callback_f)(pxml_chunk_type_e _type, - const void *_chunk_data, size_t _chunk_size, - void *_key); + const void *_chunk_data, size_t _chunk_size, + void *_key); /* * Parse the given buffer as it were a chunk of XML data. @@ -49,7 +49,7 @@ extern "C" * The next invocation of this function must account the difference. */ ssize_t pxml_parse(int *_stateContext, const void *xmlbuf, size_t _size, - pxml_callback_f *cb, void *_key); + pxml_callback_f *cb, void *_key); #ifdef __cplusplus } diff --git a/src/core/libs/supl/supl.c b/src/core/libs/supl/supl.c index b7df4acbb..8b493f7df 100644 --- a/src/core/libs/supl/supl.c +++ b/src/core/libs/supl/supl.c @@ -250,7 +250,7 @@ int EXPORT supl_server_connect(supl_ctx_t *ctx, char *server) SSLeay_add_ssl_algorithms(); // meth = TLSv1_client_method(); - meth = (SSL_METHOD*)SSLv23_client_method(); + meth = (SSL_METHOD *)SSLv23_client_method(); SSL_load_error_strings(); ctx->ssl_ctx = SSL_CTX_new(meth); if (!ctx->ssl_ctx) From 61c22ed53b5bd8033a9d06b0f40cf8c3552e7872 Mon Sep 17 00:00:00 2001 From: Carles Fernandez Date: Fri, 11 Oct 2019 12:02:53 +0200 Subject: [PATCH 2/2] Set default freq_dds_tx_hz parameter to 10 kHz --- .../signal_source/adapters/ad9361_fpga_signal_source.cc | 6 +++--- .../signal_source/adapters/fmcomms2_signal_source.cc | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/algorithms/signal_source/adapters/ad9361_fpga_signal_source.cc b/src/algorithms/signal_source/adapters/ad9361_fpga_signal_source.cc index 676956d33..77e0f4253 100644 --- a/src/algorithms/signal_source/adapters/ad9361_fpga_signal_source.cc +++ b/src/algorithms/signal_source/adapters/ad9361_fpga_signal_source.cc @@ -32,7 +32,7 @@ #include "ad9361_fpga_signal_source.h" #include "GPS_L1_CA.h" -#include "GPS_L2C.h" +#include "GPS_L5.h" #include "ad9361_manager.h" #include "configuration_interface.h" #include @@ -310,8 +310,8 @@ Ad9361FpgaSignalSource::Ad9361FpgaSignalSource(ConfigurationInterface *configura Fpass_ = configuration->property(role + ".Fpass", 0.0); Fstop_ = configuration->property(role + ".Fstop", 0.0); enable_dds_lo_ = configuration->property(role + ".enable_dds_lo", false); - freq_dds_tx_hz_ = configuration->property(role + ".freq_dds_tx_hz", 1000); - freq_rf_tx_hz_ = configuration->property(role + ".freq_rf_tx_hz", GPS_L1_FREQ_HZ - GPS_L2_FREQ_HZ - freq_dds_tx_hz_); + freq_dds_tx_hz_ = configuration->property(role + ".freq_dds_tx_hz", 10000); + freq_rf_tx_hz_ = configuration->property(role + ".freq_rf_tx_hz", GPS_L1_FREQ_HZ - GPS_L5_FREQ_HZ - freq_dds_tx_hz_); scale_dds_dbfs_ = configuration->property(role + ".scale_dds_dbfs", -3.0); tx_attenuation_db_ = configuration->property(role + ".tx_attenuation_db", default_tx_attenuation_db); tx_bandwidth_ = configuration->property(role + ".tx_bandwidth", 500000); diff --git a/src/algorithms/signal_source/adapters/fmcomms2_signal_source.cc b/src/algorithms/signal_source/adapters/fmcomms2_signal_source.cc index 87065525e..47c651da5 100644 --- a/src/algorithms/signal_source/adapters/fmcomms2_signal_source.cc +++ b/src/algorithms/signal_source/adapters/fmcomms2_signal_source.cc @@ -87,7 +87,7 @@ Fmcomms2SignalSource::Fmcomms2SignalSource(ConfigurationInterface *configuration // AD9361 Local Oscillator generation for dual band operation enable_dds_lo_ = configuration->property(role + ".enable_dds_lo", false); - freq_dds_tx_hz_ = configuration->property(role + ".freq_dds_tx_hz", 1000); + freq_dds_tx_hz_ = configuration->property(role + ".freq_dds_tx_hz", 10000); freq_rf_tx_hz_ = configuration->property(role + ".freq_rf_tx_hz", GPS_L1_FREQ_HZ - GPS_L2_FREQ_HZ - freq_dds_tx_hz_); scale_dds_dbfs_ = configuration->property(role + ".scale_dds_dbfs", 0.0); phase_dds_deg_ = configuration->property(role + ".phase_dds_deg", 0.0);