Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
7f7d116c
Kaydet (Commit)
7f7d116c
authored
Kas 07, 2013
tarafından
Michael Meeks
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
liblibo: use gettimeofday not clock_gettime for better portability.
Change-Id: Ic111faf5db7709483f20fea8cbf9ff4298301b8a
üst
6f16fd62
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
10 deletions
+7
-10
libtest.cxx
smoketest/libtest.cxx
+7
-10
No files found.
smoketest/libtest.cxx
Dosyayı görüntüle @
7f7d116c
...
...
@@ -12,10 +12,15 @@
#include <malloc.h>
#include <assert.h>
#include <math.h>
#include <time.h>
#include <
sys/
time.h>
#include <liblibreoffice.hxx>
long
getTimeMS
();
long
getTimeMS
()
{
struct
timeval
t
;
gettimeofday
(
&
t
,
NULL
);
return
t
.
tv_sec
*
1000
+
t
.
tv_usec
/
1000
;
}
static
int
help
()
{
...
...
@@ -99,12 +104,4 @@ int main (int argc, char **argv)
return
0
;
}
long
getTimeMS
()
{
struct
timespec
t
;
clock_gettime
(
CLOCK_MONOTONIC
,
&
t
);
long
ms
=
round
(
t
.
tv_nsec
/
1.0e6
)
+
t
.
tv_sec
*
1000
;
return
ms
;
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment