NetSNMP 0.3.1.0 → 0.3.2.0
raw patch · 6 files changed
+63/−43 lines, 6 filesdep ~processdep ~utf8-stringPVP: major bump suggested
API removals or changes: PVP suggests a major version bump
Dependency ranges changed: process, utf8-string
API changes (from Hackage documentation)
- Network.Protocol.NetSNMP: instance Eq ASNValue
- Network.Protocol.NetSNMP: instance Eq SnmpResult
- Network.Protocol.NetSNMP: instance Eq SnmpVersion
- Network.Protocol.NetSNMP: instance Functor Trouble
- Network.Protocol.NetSNMP: instance Monad Trouble
- Network.Protocol.NetSNMP: instance Show ASNValue
- Network.Protocol.NetSNMP: instance Show SnmpResult
- Network.Protocol.NetSNMP: instance Show SnmpVersion
- Network.Protocol.NetSNMP: instance Storable SnmpPDU
- Network.Protocol.NetSNMP: instance Storable SnmpSession
- Network.Protocol.NetSNMP: oid :: SnmpResult -> RawOID
- Network.Protocol.NetSNMP: unSnmpVersion :: SnmpVersion -> CLong
- Network.Protocol.NetSNMP: value :: SnmpResult -> ASNValue
+ Network.Protocol.NetSNMP: [oid] :: SnmpResult -> RawOID
+ Network.Protocol.NetSNMP: [unSnmpVersion] :: SnmpVersion -> CLong
+ Network.Protocol.NetSNMP: [value] :: SnmpResult -> ASNValue
+ Network.Protocol.NetSNMP: instance Foreign.Storable.Storable Network.Protocol.NetSNMP.SnmpPDU
+ Network.Protocol.NetSNMP: instance Foreign.Storable.Storable Network.Protocol.NetSNMP.SnmpSession
+ Network.Protocol.NetSNMP: instance GHC.Base.Applicative Network.Protocol.NetSNMP.Trouble
+ Network.Protocol.NetSNMP: instance GHC.Base.Functor Network.Protocol.NetSNMP.Trouble
+ Network.Protocol.NetSNMP: instance GHC.Base.Monad Network.Protocol.NetSNMP.Trouble
+ Network.Protocol.NetSNMP: instance GHC.Classes.Eq Network.Protocol.NetSNMP.ASNValue
+ Network.Protocol.NetSNMP: instance GHC.Classes.Eq Network.Protocol.NetSNMP.SnmpResult
+ Network.Protocol.NetSNMP: instance GHC.Classes.Eq Network.Protocol.NetSNMP.SnmpVersion
+ Network.Protocol.NetSNMP: instance GHC.Show.Show Network.Protocol.NetSNMP.ASNValue
+ Network.Protocol.NetSNMP: instance GHC.Show.Show Network.Protocol.NetSNMP.SnmpResult
+ Network.Protocol.NetSNMP: instance GHC.Show.Show Network.Protocol.NetSNMP.SnmpVersion
Files
- LICENSE +0/−34
- NetSNMP.cabal +6/−6
- changes +19/−0
- changes.md +0/−2
- license +29/−0
- src/Network/Protocol/NetSNMP.hsc +9/−1
− LICENSE
@@ -1,34 +0,0 @@--Copyright (c) 2009, John A. Dorsey.-All rights reserved.--Redistribution and use of this software in source and binary forms,-with or without modification, are permitted provided that the-following conditions are met:--* Redistributions of source code must retain the above- copyright notice, this list of conditions and the- following disclaimer.--* Redistributions in binary form must reproduce the above- copyright notice, this list of conditions and the- following disclaimer in the documentation and/or other- materials provided with the distribution.--* Neither the name of John Dorsey nor the names of its- contributors may be used to endorse or promote products- derived from this software without specific prior- written permission.--THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS-"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT-LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR-A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT-OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED-TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,-OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY-OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING-NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS-SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.-
NetSNMP.cabal view
@@ -1,5 +1,5 @@ name: NetSNMP-version: 0.3.1.0+version: 0.3.2.0 synopsis: Bindings for net-snmp's C API for clients description: Network.Protocol.NetSNMP is a partial binding to the library portion of the net-snmp package. It uses the@@ -11,14 +11,14 @@ category: Network cabal-version: >= 1.8 license: BSD3-license-file: LICENSE+license-file: license author: Pavlo Kerestey and Humane Software for Global Access Internet Services GmbH maintainer: Pavlo Kerestey <pavlo@kerestey.net> stability: alpha build-type: Simple homepage: https://github.com/ptek/netsnmp bug-reports: https://github.com/ptek/netsnmp/issues-extra-source-files: changes.md+extra-source-files: changes source-repository head type: git@@ -33,7 +33,7 @@ ghc-options: -Wall -static -fno-warn-missing-signatures -fno-warn-unused-binds build-depends: base >=4.5 && <5 ,bytestring >= 0.9 && < 0.11- ,utf8-string >= 0.3 && < 0.4+ ,utf8-string test-suite tests hs-source-dirs: tests@@ -43,7 +43,7 @@ main-is: RunTests.hs build-depends: base >= 4.5 && <5 ,bytestring >= 0.9 && < 0.11- ,utf8-string >= 0.3 && < 0.4+ ,utf8-string ,HUnit ,NetSNMP- ,process > 1.1 && < 1.2+ ,process
+ changes view
@@ -0,0 +1,19 @@+0.3.1.0 - 19. April 2014+ * Make the library work on Debian 7 with ByteString 0.9++0.3.0.6 * OIDpart type is hacked to work correctly on OS X++0.3.0.5 * Tied the OIDPart to the correct C Type of the oid.+ NOTE: This breaks the code on the OS X and we don't know why+ The oid of the SNMP Result can not be read correctly++0.3.0.4 * Reduced the default number of max-repetitions in Bulk PDUs to 30.+ The previous value caused oversized responses on Extreme Network+ switches.++0.3.0.3 * Fixed a bug, where instead of 32 bit, the OID part was set to CLong,+ which became 64 bit in base 4.5++0.3.* * Switch from Strings to ByteStrings++0.2.* * Implementation includes snmpBulkWalk
− changes.md
@@ -1,2 +0,0 @@-0.3.1.0 - 19. April 2014- * Make the library work on Debian 7 with ByteString 0.9
+ license view
@@ -0,0 +1,29 @@+Copyright (c) 2014, Pavlo Kerestey+All rights reserved.++Redistribution and use in source and binary forms, with or without+modification, are permitted provided that the following conditions are met:++1. Redistributions of source code must retain the above copyright+ notice, this list of conditions and the following disclaimer.++2. Redistributions in binary form must reproduce the above copyright+ notice, this list of conditions and the following disclaimer+ in the documentation and/or other materials provided with the+ distribution.++3. Neither the name of the copyright holder nor the names of its+ contributors may be used to endorse or promote products derived+ from this software without specific prior written permission.++THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE+ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE+LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR+CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF+SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS+INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN+CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)+ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF+THE POSSIBILITY OF SUCH DAMAGE.
src/Network/Protocol/NetSNMP.hsc view
@@ -28,7 +28,6 @@ ) where -import Control.Applicative import Control.Monad import Data.ByteString (ByteString) import qualified Data.ByteString as B@@ -836,6 +835,15 @@ -- type Trouble = ErrorT String IO newtype Trouble a = Trouble { runTrouble :: IO (Either String a) }++instance Applicative Trouble where+ pure a = Trouble $ pure (Right a)+ -- (<*>) :: Trouble (a -> b) -> Trouble a -> Trouble b+ f <*> v = Trouble $ do+ r <- runTrouble f+ v' <- runTrouble v+ case r of (Left s) -> return (Left s)+ (Right f') -> return (fmap f' v') instance Functor Trouble where fmap f m = Trouble $ do