Skip to content

Commit

Permalink
Merge remote-tracking branch 'stefanha/trivial-patches' into staging
Browse files Browse the repository at this point in the history
* stefanha/trivial-patches:
  configure: try pkg-config for curses
  qom: Make object_resolve_path_component() path argument const
  Add libcacard/trace/generated-tracers.c to .gitignore

Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
  • Loading branch information
Anthony Liguori committed Jan 15, 2013
2 parents b9f84ac + ecbe251 commit 58a864d
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 3 deletions.
1 change: 1 addition & 0 deletions .gitignore
Expand Up @@ -7,6 +7,7 @@ trace/generated-tracers.h
trace/generated-tracers.c
trace/generated-tracers-dtrace.h
trace/generated-tracers-dtrace.dtrace
libcacard/trace/generated-tracers.c
*-timestamp
*-softmmu
*-darwin-user
Expand Down
5 changes: 4 additions & 1 deletion configure
Expand Up @@ -2039,7 +2039,7 @@ fi
if test "$mingw32" = "yes" ; then
curses_list="-lpdcurses"
else
curses_list="-lncurses -lcurses"
curses_list="-lncurses:-lcurses:$($pkg_config --libs ncurses)"
fi

if test "$curses" != "no" ; then
Expand All @@ -2052,13 +2052,16 @@ int main(void) {
return s != 0;
}
EOF
IFS=:
for curses_lib in $curses_list; do
unset IFS
if compile_prog "" "$curses_lib" ; then
curses_found=yes
libs_softmmu="$curses_lib $libs_softmmu"
break
fi
done
unset IFS
if test "$curses_found" = "yes" ; then
curses=yes
else
Expand Down
2 changes: 1 addition & 1 deletion include/qom/object.h
Expand Up @@ -900,7 +900,7 @@ Object *object_resolve_path_type(const char *path, const char *typename,
*
* Returns: The resolved object or NULL on path lookup failure.
*/
Object *object_resolve_path_component(Object *parent, gchar *part);
Object *object_resolve_path_component(Object *parent, const gchar *part);

/**
* object_property_add_child:
Expand Down
2 changes: 1 addition & 1 deletion qom/object.c
Expand Up @@ -1017,7 +1017,7 @@ gchar *object_get_canonical_path(Object *obj)
return newpath;
}

Object *object_resolve_path_component(Object *parent, gchar *part)
Object *object_resolve_path_component(Object *parent, const gchar *part)
{
ObjectProperty *prop = object_property_find(parent, part, NULL);
if (prop == NULL) {
Expand Down

0 comments on commit 58a864d

Please sign in to comment.