php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #48342 implicit declaration of built-in function 'llabs'
Submitted: 2009-05-20 05:01 UTC Modified: 2009-05-20 13:56 UTC
From: jf at netmadeira dot com Assigned:
Status: Wont fix Package: Compile Warning
PHP Version: 5.3CVS-2009-05-20 (snap) OS: linux
Private report: No CVE-ID: None
Have you experienced this issue?
Rate the importance of this bug to you:

 [2009-05-20 05:01 UTC] jf at netmadeira dot com
Description:
------------
Received this compile warming while compilling:
(...)/php_date.c: In function 'date_format':
(...)/php_date.c:1040: warning: incompatible implicit declaration of built-in function 'llabs'

So did a grep -R llabs ./ and get:
./win32/php_stdint.h:static __inline int64_t llabs( int64_t i ) { return i >= 0? i: -i; }
./ext/date/php_date.c:			case 'Y': length = slprintf(buffer, 32, "%s%04ld", t->y < 0 ? "-" : "", llabs((timelib_sll) t->y)); break;
./ext/fileinfo/tests/magic:# from Ruda Moura <ruda@helllabs.org>

it seems llabs its only available for windows, is this right ??

Can I filter all warmings, I spotted this one because I canceled compilation right in begining and seen that, but in midle of all those lines can't spot nothing more.. 


Regards



Reproduce code:
---------------
grep -R llabs ./ in php package source.


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2009-05-20 08:19 UTC] jani@php.net
a) It's harmless
b) "Fixing" it breaks stuff with older glibc
 [2009-05-20 11:25 UTC] jani@php.net
I forgot:

# man llabs 

And also see bug #45188 (where the compile failure was reported in last comments)
 [2009-05-20 13:56 UTC] jf at netmadeira dot com
But wont it crash php if:
case 'Y': length = slprintf(buffer, 32,
"%s%04ld", t->y < 0 ? "-" : "", llabs((timelib_sll) t->y)); break;

is called ??

Sorry, didn't understand what you mean when you told to see bug #45188

I'm not native englisg speaker..


Best regards
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Apr 25 10:01:29 2024 UTC