summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Schlemmer <azarah@gentoo.org>2002-05-05 10:56:36 +0000
committerMartin Schlemmer <azarah@gentoo.org>2002-05-05 10:56:36 +0000
commit2f15eeee36aa046746843db80d1673adedbbfb87 (patch)
tree001c0274bc149ef404b75dbd932ebb18d3fc5179 /media-libs/id3lib/files
parentfinal touches (diff)
downloadgentoo-2-2f15eeee36aa046746843db80d1673adedbbfb87.tar.gz
gentoo-2-2f15eeee36aa046746843db80d1673adedbbfb87.tar.bz2
gentoo-2-2f15eeee36aa046746843db80d1673adedbbfb87.zip
bugfixes
Diffstat (limited to 'media-libs/id3lib/files')
-rw-r--r--media-libs/id3lib/files/digest-id3lib-3.8.0_pre2-r11
-rw-r--r--media-libs/id3lib/files/id3lib-3.8.0_pre2-gcc3.patch137
2 files changed, 138 insertions, 0 deletions
diff --git a/media-libs/id3lib/files/digest-id3lib-3.8.0_pre2-r1 b/media-libs/id3lib/files/digest-id3lib-3.8.0_pre2-r1
new file mode 100644
index 000000000000..72c7aeafef6d
--- /dev/null
+++ b/media-libs/id3lib/files/digest-id3lib-3.8.0_pre2-r1
@@ -0,0 +1 @@
+MD5 48444a1eb634c034c05388e8e2bb5024 id3lib-3.8.0pre2.tar.gz 680219
diff --git a/media-libs/id3lib/files/id3lib-3.8.0_pre2-gcc3.patch b/media-libs/id3lib/files/id3lib-3.8.0_pre2-gcc3.patch
new file mode 100644
index 000000000000..08b4968f503d
--- /dev/null
+++ b/media-libs/id3lib/files/id3lib-3.8.0_pre2-gcc3.patch
@@ -0,0 +1,137 @@
+diff -w -b -B -u -U 5 -r -P -x *~ -x *.[oa] id3lib-3.8.0pre2/src/tag_file.cpp id3lib-3.8.0pre2.doj/src/tag_file.cpp
+--- id3lib-3.8.0pre2/src/tag_file.cpp Sat Sep 8 04:30:18 2001
++++ id3lib-3.8.0pre2.doj/src/tag_file.cpp Thu Oct 4 23:22:40 2001
+@@ -268,18 +268,11 @@
+ }
+ char sTempFile[ID3_PATH_LENGTH];
+ strcpy(sTempFile, filename.c_str());
+ strcat(sTempFile, sTmpSuffix.c_str());
+
+- int fd = mkstemp(sTempFile);
+- if (fd < 0)
+- {
+- remove(sTempFile);
+- //ID3_THROW_DESC(ID3E_NoFile, "couldn't open temp file");
+- }
+-
+- ofstream tmpOut(fd);
++ ofstream tmpOut(sTempFile);
+ if (!tmpOut)
+ {
+ tmpOut.close();
+ remove(sTempFile);
+ return 0;
+@@ -290,13 +283,13 @@
+ tmpOut.write(tagData, tagSize);
+ file.seekg(tag.GetPrependedBytes(), ios::beg);
+ uchar tmpBuffer[BUFSIZ];
+ while (file)
+ {
+- file.read(tmpBuffer, BUFSIZ);
++ file.read((char *)tmpBuffer, BUFSIZ);
+ size_t nBytes = file.gcount();
+- tmpOut.write(tmpBuffer, nBytes);
++ tmpOut.write((char *)tmpBuffer, nBytes);
+ }
+
+ tmpOut.close();
+
+ file.close();
+diff -w -b -B -u -U 5 -r -P -x *~ -x *.[oa] id3lib-3.8.0pre2/src/utils.cpp id3lib-3.8.0pre2.doj/src/utils.cpp
+--- id3lib-3.8.0pre2/src/utils.cpp Sat Sep 8 04:30:18 2001
++++ id3lib-3.8.0pre2.doj/src/utils.cpp Thu Oct 4 23:31:17 2001
+@@ -31,12 +31,14 @@
+ #if defined HAVE_ICONV_H
+ # include <iconv.h>
+ # include <errno.h>
+ #endif
+
+-#include <ctype.h>
+-#include <iostream.h>
++#include <cctype>
++#include <iostream>
++#include <string>
++using namespace std;
+
+ #ifdef macintosh
+ #define NOCREATE ((std::ios_base::openmode)0)
+ #define toascii(X) (X)
+ #else
+@@ -115,11 +117,11 @@
+ size_t target_size = BUFSIZ;
+
+ do
+ {
+ size_t nconv = iconv(cd,
+- &source_str, &source_size,
++ (char **)&source_str, &source_size,
+ &target_str, &target_size);
+ if (nconv == (size_t) -1 && errno != EINVAL && errno != E2BIG)
+ {
+ return target;
+ }
+@@ -214,11 +216,11 @@
+
+ namespace
+ {
+ bool exists(String name)
+ {
+- ifstream file(name.c_str(), NOCREATE);
++ ifstream file(name.c_str()/*, NOCREATE*/);
+ return file.is_open() != 0;
+ }
+ };
+
+ ID3_Err dami::createFile(String name, fstream& file)
+@@ -285,11 +287,11 @@
+
+ if (file.is_open())
+ {
+ file.close();
+ }
+- file.open(name.c_str(), ios::in | ios::out | ios::binary | NOCREATE);
++ file.open(name.c_str(), ios::in | ios::out | ios::binary /*| NOCREATE*/);
+ if (!file)
+ {
+ return ID3E_ReadOnly;
+ }
+
+@@ -305,11 +307,11 @@
+
+ if (file.is_open())
+ {
+ file.close();
+ }
+- file.open(name.c_str(), ios::in | ios::out | ios::binary | NOCREATE);
++ file.open(name.c_str(), ios::in | ios::out | ios::binary /*| NOCREATE*/);
+ if (!file)
+ {
+ return ID3E_ReadOnly;
+ }
+
+@@ -320,11 +322,11 @@
+ {
+ if (file.is_open())
+ {
+ file.close();
+ }
+- file.open(name.c_str(), ios::in | ios::binary | NOCREATE);
++ file.open(name.c_str(), ios::in | ios::binary /*| NOCREATE*/);
+ if (!file)
+ {
+ return ID3E_NoFile;
+ }
+
+@@ -335,11 +337,11 @@
+ {
+ if (file.is_open())
+ {
+ file.close();
+ }
+- file.open(name.c_str(), ios::in | ios::binary | NOCREATE);
++ file.open(name.c_str(), ios::in | ios::binary /*| NOCREATE*/);
+ if (!file)
+ {
+ return ID3E_NoFile;
+ }
+