mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-06-09 12:11:20 -03:00
Use halloc in a few more places, including the highlight code
darcs-hash:20060612141233-ac50b-1c44411dd31cdc31d6ccb226f567c308c4fc0f55.gz
This commit is contained in:
14
kill.c
14
kill.c
@@ -30,6 +30,7 @@
|
||||
#include "env.h"
|
||||
#include "exec.h"
|
||||
#include "parser.h"
|
||||
#include "halloc.h"
|
||||
|
||||
/**
|
||||
Maximum entries in killring
|
||||
@@ -48,14 +49,11 @@ static wchar_t *cut_buffer=0;
|
||||
*/
|
||||
static int has_xsel()
|
||||
{
|
||||
wchar_t *path = get_filename( L"xsel" );
|
||||
if( path)
|
||||
{
|
||||
free(path);
|
||||
return 1;
|
||||
}
|
||||
else
|
||||
return 0;
|
||||
void *context = halloc(0, 0);
|
||||
wchar_t *path = parser_get_filename( context, L"xsel" );
|
||||
int res = !!path;
|
||||
halloc_free( context );
|
||||
return res;
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user