diff options
author | Adrian Knoth <adi@drcomp.erfurt.thur.de> | 2014-02-14 14:32:53 +0100 |
---|---|---|
committer | Adrian Knoth <adi@drcomp.erfurt.thur.de> | 2014-02-14 14:32:53 +0100 |
commit | e38da1ca25d81e709463c36fb2c944ebdb72399c (patch) | |
tree | b8d8252c4b910be1590b9869c398cebf91dbc12e /linux | |
parent | 527f154cbec56d10a62398e1e0fb70342774373d (diff) | |
download | jack2-e38da1ca25d81e709463c36fb2c944ebdb72399c.tar.gz |
Revert "Added Stéphane review fixes :"
This reverts commit f08a3f42343b0bb2c303aea8bc80f2bb306cb3c3.
Diffstat (limited to 'linux')
-rw-r--r-- | linux/iio/JackIIODriver.C (renamed from linux/iio/JackIIODriver.cpp) | 11 | ||||
-rw-r--r-- | linux/iio/JackIIODriver.H (renamed from linux/iio/JackIIODriver.h) | 0 | ||||
-rw-r--r-- | linux/wscript | 4 |
3 files changed, 3 insertions, 12 deletions
diff --git a/linux/iio/JackIIODriver.cpp b/linux/iio/JackIIODriver.C index 127af7be..4f934801 100644 --- a/linux/iio/JackIIODriver.cpp +++ b/linux/iio/JackIIODriver.C @@ -17,7 +17,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -#include "JackIIODriver.h" +#include "JackIIODriver.H" #include "driver_interface.h" #include "JackEngineControl.h" #include "JackGraphManager.h" @@ -175,13 +175,11 @@ SERVER_EXPORT Jack::JackDriverClientInterface* driver_initialize(Jack::JackLocke // interrogate the available iio devices searching for the chip name if (iio_driver->iio.findDevicesByChipName(chipName)!=NO_ERROR) { // find all devices with a particular chip which are present. jack_error("\nThe iio driver found no devices by the name %s\n", chipName.c_str()); - delete iio_driver; return NULL; } if (iio_driver->iio.getDeviceCnt()<1) { // If there are no devices found by that chip name, then indicate. jack_error("\nThe iio driver found no devices by the name %s\n", chipName.c_str()); - delete iio_driver; return NULL; } @@ -196,7 +194,6 @@ SERVER_EXPORT Jack::JackDriverClientInterface* driver_initialize(Jack::JackLocke int ret=iio_driver->iio.getReadArray(periodSize, iio_driver->data); // resize the array to be able to read enough memory if (ret!=NO_ERROR) { jack_error("iio::getReadArray couldn't create the data buffer, indicating the problem."); - delete iio_driver; return NULL; } if (iio_driver->data.cols()>colCnt) // resize the data columns to match the specified number of columns (channels / channels per device) @@ -204,7 +201,6 @@ SERVER_EXPORT Jack::JackDriverClientInterface* driver_initialize(Jack::JackLocke ret=iio_driver->iio.open(periodCount, periodSize); // try to open all IIO devices if (ret!=NO_ERROR) - delete iio_driver; return NULL; Jack::JackDriverClientInterface* threaded_driver = new Jack::JackThreadedDriver(iio_driver); @@ -220,11 +216,6 @@ SERVER_EXPORT Jack::JackDriverClientInterface* driver_initialize(Jack::JackLocke } else jack_error("\nHave you run out of memory ? I tried to create Jack's standard threaded driver in memory but failed! The good news is that you had enough memory to create the IIO driver.\n"); - if (!threaded_driver) { // handle the case that the threaded_driver was not created succ. - delete iio_driver; - iio_driver=NULL; - } - return threaded_driver; } diff --git a/linux/iio/JackIIODriver.h b/linux/iio/JackIIODriver.H index 1642656a..1642656a 100644 --- a/linux/iio/JackIIODriver.h +++ b/linux/iio/JackIIODriver.H diff --git a/linux/wscript b/linux/wscript index 3e7f097d..caf286a5 100644 --- a/linux/wscript +++ b/linux/wscript @@ -19,7 +19,7 @@ def configure(conf): conf.env['BUILD_DRIVER_IIO'] += conf.is_defined('HAVE_EIGEN3') conf.check_cfg(package='sox', atleast_version='14.4.0', args='--cflags --libs', mandatory=False) conf.env['BUILD_DRIVER_IIO'] += conf.is_defined('HAVE_SOX') - + def create_jack_driver_obj(bld, target, sources, uselib = None): driver = bld(features = ['c', 'cxx', 'cxxshlib', 'cshlib']) @@ -82,7 +82,7 @@ def build(bld): 'firewire/JackFFADOMidiSendQueue.cpp' ] - iio_driver_src = ['iio/JackIIODriver.cpp'] + iio_driver_src = ['iio/JackIIODriver.C'] if bld.env['BUILD_DRIVER_ALSA'] == True: create_jack_driver_obj(bld, 'alsa', alsa_driver_src, ["ALSA"]) |