# \[Bug #887\] thread.c: warning: format '%.6ld' expects type 'long int'

**URL:** <https://www.ruby-forum.com/t/bug-887-thread-c-warning-format-6ld-expects-type-long-int/155677>\
**Category:** Development\
**Created:** [December 15, 2008, 3:28pm UTC](https://www.ruby-forum.com/t/bug-887-thread-c-warning-format-6ld-expects-type-long-int/155677 "2008-12-15T15:28:49Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Kazuhiro\_NISHIYAMA](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/k/77aa72/32.png) [@Kazuhiro\_NISHIYAMA](https://www.ruby-forum.com/u/Kazuhiro_NISHIYAMA)\
**Post date:** [December 15, 2008, 3:28pm UTC](https://www.ruby-forum.com/t/bug-887-thread-c-warning-format-6ld-expects-type-long-int/155677/1 "2008-12-15T15:28:49Z")

</div>

Bug #887: thread.c: warning: format ‘%.6ld’ expects type ‘long int’  
[http://redmine.ruby-lang.org/issues/show/887](http://redmine.ruby-lang.org/issues/show/887)

e$B5/I\<\<Te(B: Kazuhiro NISHIYAMA  
e$B%9%F!\<%?%9e(B: Open, e$BM%@hEYe(B: Normal

Mac OS  
Xe$B$N4D6-$G0J2\<$Ne(Bwarninge$B$,=P$F$$$k$N$G!"e(Btv\_sece$B$@$1$G$O$J$/e(Btv\_usece$B$be(Blonge$B$K%-%c%9%H$7$F$7$^$($PNI$$$N$G$O$J$$$G$7$g$&$+!#e(B

gcc -DRUBY\_DEBUG\_ENV -O2 -g -Wall -Wformat=2 -Wundef -Wno-parentheses  
-pipe -fno-common -I. -I.ext/include/powerpc-darwin9.5.0 -I./include  
-I. -DRUBY\_EXPORT -D\_XOPEN\_SOURCE -D\_DARWIN\_C\_SOURCE -o thread.o -c  
thread.c  
thread.c: In function ‘sleep\_timeval’:  
thread.c:809: warning: format ‘%.6ld’ expects type ‘long int’, but  
argument 3 has type ‘\_\_darwin\_suseconds\_t’  
thread.c:809: warning: format ‘%.6ld’ expects type ‘long int’, but  
argument 5 has type ‘\_\_darwin\_suseconds\_t’

---

<div class="post-metadata">

**Author:** ![Kazuhiro\_NISHIYAMA](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/k/77aa72/32.png) [@Kazuhiro\_NISHIYAMA](https://www.ruby-forum.com/u/Kazuhiro_NISHIYAMA)\
**Post date:** [December 15, 2008, 4:01pm UTC](https://www.ruby-forum.com/t/bug-887-thread-c-warning-format-6ld-expects-type-long-int/155677/2 "2008-12-15T16:01:48Z")

</div>

e$B%A%1%C%He(B #887 e$B$,99?7$5$l$^$7$?!#e(B (by Yukihiro M.)

e$B%9%F!\<%?%9e(B Opene$B$+$ie(BClosede$B$KJQ99e(B  
e$B?JD=e(B % 0e$B$+$ie(B100e$B$KJQ99e(B

## Applied in changeset r20766.

[http://redmine.ruby-lang.org/issues/show/887](http://redmine.ruby-lang.org/issues/show/887)
