mirror of
https://github.com/GothenburgBitFactory/taskwarrior.git
synced 2025-08-27 19:17:19 +02:00
FreeBSD
- Converted __FreeBSD__ to FREEBSD for consistency.
This commit is contained in:
parent
da7cc6eed7
commit
04e0df6965
3 changed files with 13 additions and 10 deletions
|
@ -43,6 +43,8 @@ Features
|
||||||
+ Protects against interrupt during critical DB commit and sync operations.
|
+ Protects against interrupt during critical DB commit and sync operations.
|
||||||
+ The 'push', 'pull' and 'merge' commands now generate a 'deprecated' message.
|
+ The 'push', 'pull' and 'merge' commands now generate a 'deprecated' message.
|
||||||
+ Rewritten task-sync(5) man page, listing sync options and setup guidelines..
|
+ Rewritten task-sync(5) man page, listing sync options and setup guidelines..
|
||||||
|
+ Now properly uses the libc version of uuid_create and uuid_to_string for
|
||||||
|
FreeBSD (thanks to Pietro Cerutti).
|
||||||
|
|
||||||
Bugs
|
Bugs
|
||||||
+ #1195 Random seed not random enough - removed all random number code (thanks
|
+ #1195 Random seed not random enough - removed all random number code (thanks
|
||||||
|
|
18
src/util.cpp
18
src/util.cpp
|
@ -235,19 +235,19 @@ int autoComplete (
|
||||||
// representation is always lowercase anyway.
|
// representation is always lowercase anyway.
|
||||||
// For the implementation details, refer to
|
// For the implementation details, refer to
|
||||||
// http://svnweb.freebsd.org/base/head/sys/kern/kern_uuid.c
|
// http://svnweb.freebsd.org/base/head/sys/kern/kern_uuid.c
|
||||||
#ifdef __FreeBSD__
|
#ifdef FREEBSD
|
||||||
const std::string uuid ()
|
const std::string uuid ()
|
||||||
{
|
{
|
||||||
uuid_t id;
|
uuid_t id;
|
||||||
uint32_t status;
|
uint32_t status;
|
||||||
char *buffer (0);
|
char *buffer (0);
|
||||||
uuid_create (&id, &status);
|
uuid_create (&id, &status);
|
||||||
uuid_to_string (&id, &buffer, &status);
|
uuid_to_string (&id, &buffer, &status);
|
||||||
|
|
||||||
std::string res (buffer);
|
std::string res (buffer);
|
||||||
free (buffer);
|
free (buffer);
|
||||||
|
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
|
|
||||||
|
|
|
@ -28,11 +28,12 @@
|
||||||
#ifndef INCLUDED_UTIL
|
#ifndef INCLUDED_UTIL
|
||||||
#define INCLUDED_UTIL
|
#define INCLUDED_UTIL
|
||||||
|
|
||||||
|
#include <cmake.h>
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
#include <map>
|
#include <map>
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
#ifdef __FreeBSD__
|
#ifdef FREEBSD
|
||||||
#include <uuid.h>
|
#include <uuid.h>
|
||||||
#else
|
#else
|
||||||
#include <uuid/uuid.h>
|
#include <uuid/uuid.h>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue