Package: toshset
Severity: normal
Tags: patch
The patch below allows toshset to compile under gcc-3.4.
--- toshset.cc.orig 2005-06-23 15:06:35.000000000 -0700
+++ toshset.cc 2005-06-23 15:07:29.000000000 -0700
@@ -1030,10 +1030,14 @@
if ((*s)[0]=='0' &&
tolower((*s)[1])=='x') {
IStringStream is( (*s)+2 );
- is >> hex >> reg.ecx;
+ unsigned int tmp;
+ is >> hex >> tmp;
+ reg.ecx = tmp;
} else {
IStringStream is( *s );
- is >> reg.ecx;
+ unsigned int tmp;
+ is >> tmp;
+ reg.ecx = tmp;
}
cout << "setting lba to " << reg.ecx << '\n';
int ret = HciFunction( ® );
@@ -1076,10 +1080,14 @@
if ((*s)[0]=='0' &&
tolower((*s)[1])=='x') {
IStringStream is( (*s)+2 );
- is >> hex >> reg.ecx;
+ unsigned int tmp;
+ is >> hex >> tmp;
+ reg.ecx = tmp;
} else {
IStringStream is( *s );
- is >> reg.ecx;
+ unsigned int tmp;
+ is >> tmp;
+ reg.ecx = tmp;
}
String type = "invalid";
switch (hibInfoMode) {
--- cdsMath.cc.orig 2005-06-24 22:17:47.000000000 -0700
+++ cdsMath.cc 2005-06-24 22:27:30.000000000 -0700
@@ -1,6 +1,7 @@
//#include <sthead.hh>
#include <cdsMath.hh>
+#include <cstdlib> // for std::abs
namespace CDS {
@@ -25,7 +26,7 @@
- works for negative integers too*/
{
T temp = 1;
- for (int cnt=0 ; cnt<abs(i) ; cnt++) temp *= x;
+ for (int cnt=0 ; cnt<std::abs(i) ; cnt++) temp *= x;
if (i<0 && temp != 0.0) temp = 1.0 / temp;
-- System Information:
Debian Release: 3.1
APT prefers testing
APT policy: (500, 'testing')
Architecture: i386 (i686)
Kernel: Linux 2.6.8-1-386
Locale: LANG=en_US, LC_CTYPE=en_US (charmap=ISO-8859-1)
Versions of packages toshset depends on:
ii debconf [debconf-2.0] 1.4.30.11 Debian configuration management sy
ii libc6 2.3.2.ds1-22 GNU C Library: Shared libraries an
ii libgcc1 1:3.4.3-12 GCC support library
ii libstdc++5 1:3.3.5-8 The GNU Standard C++ Library v3
--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]