Message ID | 20170206044129.19436-2-aserdean@cloudbasesolutions.com |
---|---|
State | Accepted |
Headers | show |
On 5 February 2017 at 20:41, Alin Serdean <aserdean@cloudbasesolutions.com> wrote: > getrusage is implemented in lib/getrusage-windows.c. > > This patch just adds its definition to include/windows/sys/resource.h, > which serves for files that include <sys/resource.h>. > > Another that we could also do is to move the implementation to > include/windows > > Signed-off-by: Alin Gabriel Serdean <aserdean@cloudbasesolutions.com> > Applied to master. > --- > include/windows/sys/resource.h | 4 +++- > 1 file changed, 3 insertions(+), 1 deletion(-) > > diff --git a/include/windows/sys/resource.h b/include/windows/sys/ > resource.h > index d4628f2..d8f2607 100644 > --- a/include/windows/sys/resource.h > +++ b/include/windows/sys/resource.h > @@ -1,5 +1,5 @@ > /* > - * Copyright (c) 2014 Nicira, Inc. > + * Copyright (c) 2014, 2017 Nicira, Inc. > * > * Licensed under the Apache License, Version 2.0 (the "License"); > * you may not use this file except in compliance with the License. > @@ -48,4 +48,6 @@ struct rusage { > #define RUSAGE_THREAD 3 > #endif > > +int getrusage(int who, struct rusage *usage); > + > #endif /* sys/resource.h */ > -- > 2.10.2.windows.1 > _______________________________________________ > dev mailing list > dev@openvswitch.org > https://mail.openvswitch.org/mailman/listinfo/ovs-dev >
diff --git a/include/windows/sys/resource.h b/include/windows/sys/resource.h index d4628f2..d8f2607 100644 --- a/include/windows/sys/resource.h +++ b/include/windows/sys/resource.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014 Nicira, Inc. + * Copyright (c) 2014, 2017 Nicira, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -48,4 +48,6 @@ struct rusage { #define RUSAGE_THREAD 3 #endif +int getrusage(int who, struct rusage *usage); + #endif /* sys/resource.h */
getrusage is implemented in lib/getrusage-windows.c. This patch just adds its definition to include/windows/sys/resource.h, which serves for files that include <sys/resource.h>. Another that we could also do is to move the implementation to include/windows Signed-off-by: Alin Gabriel Serdean <aserdean@cloudbasesolutions.com> --- include/windows/sys/resource.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)