mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-15 11:06:32 +01:00
Switch RDFF to 2-clause BSD license.
Fix whitespace. git-svn-id: svn://localhost/ardour2/branches/3.0@9222 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
parent
09943e1d57
commit
c9d0c2beae
2 changed files with 47 additions and 34 deletions
|
|
@ -2,20 +2,26 @@
|
||||||
RDFF - RDF in RIFF
|
RDFF - RDF in RIFF
|
||||||
Copyright 2011 David Robillard <http://drobilla.net>
|
Copyright 2011 David Robillard <http://drobilla.net>
|
||||||
|
|
||||||
This is free software; you can redistribute it and/or modify it
|
Redistribution and use in source and binary forms, with or without
|
||||||
under the terms of the GNU General Public License as published by
|
modification, are permitted provided that the following conditions are met:
|
||||||
the Free Software Foundation; either version 2 of the License, or
|
|
||||||
(at your option) any later version.
|
|
||||||
|
|
||||||
This software is distributed in the hope that it will be useful,
|
1. Redistributions of source code must retain the above copyright notice,
|
||||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
this list of conditions and the following disclaimer.
|
||||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
|
||||||
See the GNU General Public License for more details.
|
|
||||||
|
|
||||||
You should have received a copy of the GNU General Public License
|
2. Redistributions in binary form must reproduce the above copyright
|
||||||
along with this sofware; if not, write to the Free Software
|
notice, this list of conditions and the following disclaimer in the
|
||||||
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
|
documentation and/or other materials provided with the distribution.
|
||||||
02110-1301 USA.
|
|
||||||
|
THIS SOFTWARE IS PROVIDED ``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
|
||||||
|
AUTHOR 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.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <assert.h>
|
#include <assert.h>
|
||||||
|
|
@ -52,7 +58,7 @@ rdff_open(const char* path, bool write)
|
||||||
if (write) {
|
if (write) {
|
||||||
fwrite("RIFF", CHUNK_ID_LEN, 1, fd); /* RIFF chunk ID */
|
fwrite("RIFF", CHUNK_ID_LEN, 1, fd); /* RIFF chunk ID */
|
||||||
fwrite(&size, sizeof(size), 1, fd); /* RIFF chunk size */
|
fwrite(&size, sizeof(size), 1, fd); /* RIFF chunk size */
|
||||||
fwrite(FILE_TYPE, CHUNK_ID_LEN, 1, fd); /* LV2 RIFF file type */
|
fwrite(FILE_TYPE, CHUNK_ID_LEN, 1, fd); /* File type */
|
||||||
} else {
|
} else {
|
||||||
char magic[CHUNK_ID_LEN];
|
char magic[CHUNK_ID_LEN];
|
||||||
if (fread(magic, CHUNK_ID_LEN, 1, fd) != 1
|
if (fread(magic, CHUNK_ID_LEN, 1, fd) != 1
|
||||||
|
|
@ -71,7 +77,8 @@ rdff_open(const char* path, bool write)
|
||||||
if (fread(magic, CHUNK_ID_LEN, 1, fd) != 1
|
if (fread(magic, CHUNK_ID_LEN, 1, fd) != 1
|
||||||
|| strncmp(magic, FILE_TYPE, CHUNK_ID_LEN)) {
|
|| strncmp(magic, FILE_TYPE, CHUNK_ID_LEN)) {
|
||||||
fclose(fd);
|
fclose(fd);
|
||||||
fprintf(stderr, "%s: error: not an LV2 RIFF file\n", path);
|
fprintf(stderr, "%s: error: not an %s RIFF file\n",
|
||||||
|
FILE_TYPE, path);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -2,20 +2,26 @@
|
||||||
RDFF - RDF in RIFF
|
RDFF - RDF in RIFF
|
||||||
Copyright 2011 David Robillard <http://drobilla.net>
|
Copyright 2011 David Robillard <http://drobilla.net>
|
||||||
|
|
||||||
This is free software; you can redistribute it and/or modify it
|
Redistribution and use in source and binary forms, with or without
|
||||||
under the terms of the GNU General Public License as published by
|
modification, are permitted provided that the following conditions are met:
|
||||||
the Free Software Foundation; either version 2 of the License, or
|
|
||||||
(at your option) any later version.
|
|
||||||
|
|
||||||
This software is distributed in the hope that it will be useful,
|
1. Redistributions of source code must retain the above copyright notice,
|
||||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
this list of conditions and the following disclaimer.
|
||||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
||||||
General Public License for more details.
|
|
||||||
|
|
||||||
You should have received a copy of the GNU General Public License
|
2. Redistributions in binary form must reproduce the above copyright
|
||||||
along with this sofware; if not, write to the Free Software
|
notice, this list of conditions and the following disclaimer in the
|
||||||
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
|
documentation and/or other materials provided with the distribution.
|
||||||
02110-1301 USA.
|
|
||||||
|
THIS SOFTWARE IS PROVIDED ``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
|
||||||
|
AUTHOR 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.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef RDFF_RDFF_H
|
#ifndef RDFF_RDFF_H
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue