!20 fix build failed
From: @disnight Reviewed-by: @small_leek,@jingxiaolu Signed-off-by: @jingxiaolu
This commit is contained in:
commit
e7dad3bdd1
@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
Name: freeimage
|
Name: freeimage
|
||||||
Version: 3.18.0
|
Version: 3.18.0
|
||||||
Release: 5
|
Release: 6
|
||||||
Summary: FreeImage is a library project for developers who would like to support popular graphics image formats (PNG, JPEG, TIFF, BMP and others)
|
Summary: FreeImage is a library project for developers who would like to support popular graphics image formats (PNG, JPEG, TIFF, BMP and others)
|
||||||
License: GPLv2 or GPLv3 and FIPL
|
License: GPLv2 or GPLv3 and FIPL
|
||||||
URL: https://freeimage.sourceforge.io/
|
URL: https://freeimage.sourceforge.io/
|
||||||
@ -105,6 +105,9 @@ ldconfig -n %{buildroot}%{_libdir}
|
|||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Tue Feb 09 2021 Jiachen Fan <fanjiachen3@huawei.com> -3.18.0-6
|
||||||
|
- correct the substream.patch: correct the line
|
||||||
|
|
||||||
* Wed Dec 16 2020 Senlin <xiasenlin1@huawei.com> -3.18.0-5
|
* Wed Dec 16 2020 Senlin <xiasenlin1@huawei.com> -3.18.0-5
|
||||||
- correct the substream.patch: add an empty line at end of file
|
- correct the substream.patch: add an empty line at end of file
|
||||||
|
|
||||||
|
|||||||
@ -1,43 +1,50 @@
|
|||||||
--- a/Source/FreeImage/PluginRAW.cpp~ 2020-05-08 08:27:31.000000000 -0500
|
--- a/Source/FreeImage/PluginRAW.cpp~ 2020-05-08 08:27:31.000000000 -0500
|
||||||
+++ a/Source/FreeImage/PluginRAW.cpp 2020-05-08 08:47:09.011816310 -0500
|
+++ b/Source/FreeImage/PluginRAW.cpp 2020-05-08 08:47:09.011816310 -0500
|
||||||
@@ -63,17 +63,17 @@
|
@@ -63,17 +63,14 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
int read(void *buffer, size_t size, size_t count) {
|
int read(void *buffer, size_t size, size_t count) {
|
||||||
return _io->read_proc(buffer, (unsigned)size, (unsigned)count, _handle);
|
- if(substream) return substream->read(buffer, size, count);
|
||||||
}
|
return _io->read_proc(buffer, (unsigned)size, (unsigned)count, _handle);
|
||||||
|
}
|
||||||
int seek(INT64 offset, int origin) {
|
|
||||||
return _io->seek_proc(_handle, (long)offset, origin);
|
int seek(INT64 offset, int origin) {
|
||||||
}
|
- if(substream) return substream->seek(offset, origin);
|
||||||
|
return _io->seek_proc(_handle, (long)offset, origin);
|
||||||
INT64 tell() {
|
}
|
||||||
return _io->tell_proc(_handle);
|
|
||||||
}
|
INT64 tell() {
|
||||||
|
- if(substream) return substream->tell();
|
||||||
@@ -83,13 +83,13 @@
|
return _io->tell_proc(_handle);
|
||||||
|
}
|
||||||
int get_char() {
|
|
||||||
int c = 0;
|
@@ -83,13 +80,11 @@
|
||||||
if(!_io->read_proc(&c, 1, 1, _handle)) return -1;
|
|
||||||
return c;
|
int get_char() {
|
||||||
}
|
int c = 0;
|
||||||
|
- if(substream) return substream->get_char();
|
||||||
char* gets(char *buffer, int length) {
|
if(!_io->read_proc(&c, 1, 1, _handle)) return -1;
|
||||||
memset(buffer, 0, length);
|
return c;
|
||||||
for(int i = 0; i < length; i++) {
|
}
|
||||||
if(!_io->read_proc(&buffer[i], 1, 1, _handle))
|
|
||||||
@@ -104,7 +104,7 @@
|
char* gets(char *buffer, int length) {
|
||||||
std::string buffer;
|
- if (substream) return substream->gets(buffer, length);
|
||||||
char element = 0;
|
memset(buffer, 0, length);
|
||||||
bool bDone = false;
|
for(int i = 0; i < length; i++) {
|
||||||
do {
|
if(!_io->read_proc(&buffer[i], 1, 1, _handle))
|
||||||
if(_io->read_proc(&element, 1, 1, _handle) == 1) {
|
@@ -104,7 +99,6 @@
|
||||||
switch(element) {
|
std::string buffer;
|
||||||
@@ -127,7 +127,7 @@
|
char element = 0;
|
||||||
}
|
bool bDone = false;
|
||||||
|
- if(substream) return substream->scanf_one(fmt,val);
|
||||||
int eof() {
|
do {
|
||||||
return (_io->tell_proc(_handle) >= _eof);
|
if(_io->read_proc(&element, 1, 1, _handle) == 1) {
|
||||||
}
|
switch(element) {
|
||||||
|
@@ -127,7 +121,6 @@
|
||||||
|
}
|
||||||
|
|
||||||
|
int eof() {
|
||||||
|
- if(substream) return substream->eof();
|
||||||
|
return (_io->tell_proc(_handle) >= _eof);
|
||||||
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user