Thread pack mal wieder (3 answers)
Opened by mark05 at 2011-06-07 14:23

mark05
 2011-06-07 15:56
#149509 #149509
User since
2010-01-05
129 Artikel
BenutzerIn
[default_avatar]
hi

koennte das so halb wegs passen ?

Code: (dl )
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
if ( $platform =~ /i486/smx ) {
my ($byteoffset1,$byteoffset2,undef,$filenumber) = unpack'lssLL',${$buffer};
use Math::BigInt;
my $sign=($byteoffset1&0x80000000);
if($sign) {
$byteoffset1^=-1;
$byteoffset2^=-1;
++$byteoffeset2;
$byteoffset2%=2**32;
++$byteoffset1 unless $byteoffset2;
}
my $i=new Math::BigInt $byteoffeset1;
$i*=2**32;
$i+=$byteoffset2;
if ( $sign ) { $i=-$i ; } ;
$byteoffset = $i;
}


habe hierfuer code von
[url]http://www.perlmonks.org/?node_id=163123[/code]
verwendet

View full thread pack mal wieder