]> sigrok.org Git - libsigrok.git/commitdiff
bindings: Update for input API changes.
authorMartin Ling <redacted>
Sat, 27 Sep 2014 15:29:34 +0000 (16:29 +0100)
committerBert Vermeulen <redacted>
Mon, 29 Sep 2014 23:50:17 +0000 (01:50 +0200)
bindings/cxx/classes.cpp
bindings/cxx/include/libsigrok/libsigrok.hpp

index 7a6daa92df7c664c8251f18133fc69586a5aa740..986d4a73086c97d52d6a4e3a353ea14fb1572f4e 100644 (file)
@@ -1289,11 +1289,16 @@ void Input::send(string data)
        check(ret);
 }
 
+void Input::end()
+{
+       check(sr_input_end(_structure));
+}
+
 Input::~Input()
 {
        if (_device)
                delete _device;
-       check(sr_input_free(_structure));
+       sr_input_free(_structure);
 }
 
 InputDevice::InputDevice(shared_ptr<Input> input,
index 972bde883d523fccec8f7324a9dc05dea06f6972..9c211837b12b01cc915ce064e1da9dae440bac52 100644 (file)
@@ -821,6 +821,8 @@ public:
        /** Send next stream data.
         * @param data Next stream data. */
        void send(string data);
+       /** Signal end of input data. */
+       void end();
 protected:
        Input(shared_ptr<Context> context, const struct sr_input *structure);
        ~Input();