octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: MSVC patch: implement getrusage


From: David Bateman
Subject: Re: MSVC patch: implement getrusage
Date: Wed, 10 Jan 2007 13:31:21 +0100
User-agent: Thunderbird 1.5.0.7 (X11/20060921)

address@hidden wrote:
> Index: src/DLD-FUNCTIONS/getrusage.cc
> ===================================================================
> RCS file: /cvs/octave/src/DLD-FUNCTIONS/getrusage.cc,v
> retrieving revision 1.11
> diff -c -p -r1.11 getrusage.cc
> *** src/DLD-FUNCTIONS/getrusage.cc      23 May 2006 06:05:14
> -0000      1.11
> --- src/DLD-FUNCTIONS/getrusage.cc      10 Jan 2007 12:10:01 -0000
> *************** elements @code{sec} (seconds) @code{usec
> *** 196,202 ****
>     tv_tmp.assign ("usec", static_cast<double> (fraction * 1e6 / HZ));
>     m.assign ("stime", octave_value (tv_tmp));
>  
> ! #elif defined (__MINGW32__)
>     HANDLE hProcess = GetCurrentProcess ();
>     FILETIME ftCreation, ftExit, ftUser, ftKernel;
>     GetProcessTimes (hProcess, &ftCreation, &ftExit, &ftKernel, &ftUser);
> --- 196,2! 02 ----
>     tv_tmp.assign ("usec", static_cast<double> (fraction * 1e6 / HZ));
>     m.assign ("stime", octave_value (tv_tmp));
>  
> ! #elif defined (__WIN32__)
>     HANDLE hProcess = GetCurrentProcess ();
>     FILETIME ftCreation, ftExit, ftUser, ftKernel;
>     GetProcessTimes (hProcess, &ftCreation, &ftExit, &ftKernel, &ftUser);
>

I think you might need to change the

#if defined (__MINGW32__)
#include <windows.h>
#endif

in this file as well..

D.



-- 
David Bateman                                address@hidden
Motorola Labs - Paris                        +33 1 69 35 48 04 (Ph) 
Parc Les Algorithmes, Commune de St Aubin    +33 6 72 01 06 33 (Mob) 
91193 Gif-Sur-Yvette FRANCE                  +33 1 69 35 77 01 (Fax) 

The information contained in this communication has been classified as: 

[x] General Business Information 
[ ] Motorola Internal Use Only 
[ ] Motorola Confidential Proprietary



reply via email to

[Prev in Thread] Current Thread [Next in Thread]