kopia lustrzana https://github.com/Hamlib/Hamlib
Quell clang6 warning of integer adsolute function
Thw warning was: CC meade.lo ../../hamlib/meade/meade.c:226:8: warning: using integer absolute value function 'abs' when argument is of floating point type [-Wabsolute-value] if(abs(az - priv->target_az) > 5 || abs(el - priv->target_el) > 5) ^ ../../hamlib/meade/meade.c:226:8: note: use function 'fabsf' instead if(abs(az - priv->target_az) > 5 || abs(el - priv->target_el) > 5) ^~~ fabsf ../../hamlib/meade/meade.c:226:41: warning: using integer absolute value function 'abs' when argument is of floating point type [-Wabsolute-value] if(abs(az - priv->target_az) > 5 || abs(el - priv->target_el) > 5) ^ ../../hamlib/meade/meade.c:226:41: note: use function 'fabsf' instead if(abs(az - priv->target_az) > 5 || abs(el - priv->target_el) > 5) ^~~ fabsf 2 warnings generated.pull/60/head
rodzic
ff4f7e1235
commit
3a6f3bac96
|
@ -223,7 +223,7 @@ static int meade_set_position(ROT *rot, azimuth_t az, elevation_t el)
|
|||
if not, don't accept new target*/
|
||||
meade_transaction(rot, ":D#", return_str, &return_str_size, 1);
|
||||
if(return_str_size > 0 && return_str[0] == 0x7F) {
|
||||
if(abs(az - priv->target_az) > 5 || abs(el - priv->target_el) > 5)
|
||||
if(fabsf(az - priv->target_az) > 5 || fabsf(el - priv->target_el) > 5)
|
||||
meade_transaction(rot, ":Q#", NULL, 0, 0);
|
||||
else
|
||||
return RIG_OK;
|
||||
|
|
Ładowanie…
Reference in New Issue