[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [xen-devel][PATCH 2/5] Xl interface change plus changes to code it impacts
Ian Campbell wrote: >> -static int validate_virtual_disk(libxl_ctx *ctx, char *file_name, >> libxl_disk_phystype disk_type) >> +static int validate_virtual_disk(libxl_ctx *ctx, char *file_name, >> + libxl_disk_backend backend_type, libxl_disk_format format) >> { >> struct stat stat_buf; >> >> - if ( (file_name[0] == '\0') && (disk_type == PHYSTYPE_EMPTY) ) >> + if ((file_name[0] == '\0') && (format == DISK_FORMAT_EMPTY)) >> return 0; > > If format == DISK_FORMAT_EMPTY then does the content of file_name > matter? > Good catch! Just checking for format should do. I will make that change. > Alternatively, if format == DISK_FORMAT_EMPTY then is file_name != "" > actually an error? > Ideally we should never end up that way as our code checks the string before setting format to DISK_FORMAT_EMPTY. Kamala _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |