enough with umpteen "i18n.h" files. Consolidate on pbd/i18n.h
[ardour.git] / libs / ardour / io_processor.cc
index 824006206fac1bb919d68d24a4dd226905a4ffac..61bb97f0ad82a392721a4c6100dc562a697a6af6 100644 (file)
@@ -32,7 +32,7 @@
 #include "ardour/session_object.h"
 #include "ardour/types.h"
 
-#include "i18n.h"
+#include "pbd/i18n.h"
 
 using namespace std;
 using namespace ARDOUR;
@@ -147,7 +147,7 @@ IOProcessor::set_state (const XMLNode& node, int version)
                return set_state_2X (node, version);
        }
 
-       const XMLProperty *prop;
+       XMLProperty const * prop;
        const XMLNode *io_node = 0;
 
        Processor::set_state(node, version);
@@ -168,9 +168,9 @@ IOProcessor::set_state (const XMLNode& node, int version)
        const string instr = enum_2_string (IO::Input);
        const string outstr = enum_2_string (IO::Output);
 
-       if (_own_input) {
+       if (_own_input && _input) {
                for (niter = nlist.begin(); niter != nlist.end(); ++niter) {
-                       const XMLProperty* prop;
+                       XMLProperty const * prop;
                        if ((prop = (*niter)->property ("name")) != 0) {
                                if (_name == prop->value()) {
                                        if ((prop = (*niter)->property ("direction")) != 0) {
@@ -197,10 +197,10 @@ IOProcessor::set_state (const XMLNode& node, int version)
 
        }
 
-       if (_own_output) {
+       if (_own_output && _output) {
                for (niter = nlist.begin(); niter != nlist.end(); ++niter) {
                        if ((*niter)->name() == "IO") {
-                               const XMLProperty* prop;
+                               XMLProperty const * prop;
                                if ((prop = (*niter)->property ("name")) != 0) {
                                        if (_name == prop->value()) {
                                                if ((prop = (*niter)->property ("direction")) != 0) {
@@ -240,7 +240,7 @@ IOProcessor::set_state_2X (const XMLNode& node, int version)
 }
 
 void
-IOProcessor::silence (framecnt_t nframes)
+IOProcessor::silence (framecnt_t nframes, framepos_t /* start_frame */)
 {
        if (_own_output && _output) {
                _output->silence (nframes);