From: <car...@us...> - 2012-08-27 01:58:20
|
Revision: 10922 http://octave.svn.sourceforge.net/octave/?rev=10922&view=rev Author: carandraug Date: 2012-08-27 01:58:14 +0000 (Mon, 27 Aug 2012) Log Message: ----------- xcorr2: check if input is 2D only Modified Paths: -------------- trunk/octave-forge/main/signal/inst/xcorr2.m Modified: trunk/octave-forge/main/signal/inst/xcorr2.m =================================================================== --- trunk/octave-forge/main/signal/inst/xcorr2.m 2012-08-27 01:53:16 UTC (rev 10921) +++ trunk/octave-forge/main/signal/inst/xcorr2.m 2012-08-27 01:58:14 UTC (rev 10922) @@ -64,6 +64,9 @@ ## will fail with "`a' undefined" error rather that print_usage b = a; endif + if (ndims (a) != 2 || ndims (b) != 2) + error ("xcorr2: input matrices must must have only 2 dimensions"); + endif ## compute correlation [ma,na] = size(a); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |