Mantis Bugtracker

Viewing Issue Simple Details Jump to Notes ] View Advanced ] Issue History ] Print ]
ID Category Severity Reproducibility Date Submitted Last Update
0000374 [Yate - Yet Another Telephony Engine] user interface minor always 2014-09-24 15:59 2015-02-26 12:01
Reporter wkg View Status public  
Assigned To
Priority normal Resolution open  
Status feedback   Product Version 4.x
Summary 0000374: yate-qt4 show history all calls as "1970.01.01 03:00"
Description if i manual change "time=1411561115.704" to "time=1411561115" in "~/.yate/client_history.conf" then show normal...
top record i'm change manual in file...

and duration same...
Additional Information system - Gentoo x86
Tags No tags attached.
Attached Files png file icon 1.png [^] (27,468 bytes) 2014-09-24 15:59
? file icon gentoo_amd64.patch [^] (227 bytes) 2014-11-02 20:58

- Relationships

-  Notes
(0000553)
paulc (administrator)
2014-09-24 17:29

Can you please detail the Gentoo version and the system language?

cat /etc/issue

set | grep '^\(LANG\|LC_\)'
(0000554)
wkg (reporter)
2014-09-24 19:20
edited on: 2014-09-24 19:31

# cat /etc/issue

This is \n.\O (\s \m \r) \t


#cat /etc/gentoo-release
Gentoo Base System release 2.2

# cat /etc/os-release
NAME=Gentoo
ID=gentoo
PRETTY_NAME="Gentoo/Linux"
ANSI_COLOR="1;32"
HOME_URL="http://www.gentoo.org/" [^]
SUPPORT_URL="http://www.gentoo.org/main/en/support.xml" [^]
BUG_REPORT_URL="https://bugs.gentoo.org/" [^]

# set | grep '^\(LANG\|LC_\)'
LANG=ru_RU.UTF-8
LC_ALL=ru_RU.UTF-8
LC_MESSAGES=ru_RU.UTF-8
LC_NUMERIC=C

i'm update gentoo every day...

try compile yate from svn, the problem remains...

(0000560)
wkg (reporter)
2014-11-02 20:58
edited on: 2014-11-02 21:01

Please see my patch. with him this bug is corrected for me.
I badly programmed and do not know why there "*eptr", but look, it may not really need?

with "if (!eptr || *eptr)" all double numbers converts from string to 0...

--- engine/String.cpp
+++ engine/String.cpp
@@ -641,7 +641,7 @@
        return defvalue;
     char *eptr = 0;
     double val= ::strtod(m_string,&eptr);
- if (!eptr || *eptr)
+ if (!eptr)
        return defvalue;
     return val;
 }

(0000561)
wkg (reporter)
2014-11-02 21:19
edited on: 2014-11-02 21:20

double val= ::strtod(m_string,&eptr);
    std::cout << "!!!" << *eptr << "!!!\n";


!!!.!!!
!!!.!!!
!!!.!!!
!!!.!!!
!!!.!!!
!!!.!!!
!!!.!!!
!!!.!!!


his always dot, is never zero ...

"endptr
Reference to an already allocated object of type char*, whose value is set by the function to the next character in str after the numerical value.
This parameter can also be a null pointer, in which case it is not used." http://www.cplusplus.com/reference/cstdlib/strtod/ [^]

"next character in str after the numerical value" in "time=1411561115.704" always to be dot, or am I wrong?

(0000591)
paulc (administrator)
2015-02-26 12:01

The dot should be part of the double precision number.

This bug appears to be caused by strtod ignoring LC_NUMERIC override on systems where locales indicate a different decimal separator.

- Issue History
Date Modified Username Field Change
2014-09-24 15:59 wkg New Issue
2014-09-24 15:59 wkg File Added: 1.png
2014-09-24 17:29 paulc Note Added: 0000553
2014-09-24 17:29 paulc Status new => feedback
2014-09-24 19:20 wkg Note Added: 0000554
2014-09-24 19:23 wkg Note Added: 0000555
2014-09-24 19:31 wkg Note Edited: 0000554
2014-09-24 19:31 wkg Note Deleted: 0000555
2014-11-02 20:58 wkg Note Added: 0000560
2014-11-02 20:58 wkg File Added: gentoo_amd64.patch
2014-11-02 20:59 wkg Note Edited: 0000560
2014-11-02 21:00 wkg Issue Monitored: wkg
2014-11-02 21:01 wkg Note Edited: 0000560
2014-11-02 21:19 wkg Note Added: 0000561
2014-11-02 21:20 wkg Note Edited: 0000561
2014-11-02 21:20 wkg Note Edited: 0000561
2014-11-02 21:20 wkg Note Edited: 0000561
2015-02-26 12:01 paulc Note Added: 0000591


Copyright © 2000 - 2008 Mantis Group
Powered by Mantis Bugtracker