Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(81)

Unified Diff: examples/albumart.c

Issue 2364793002: Revert "Uprev libmtp to 1.1.12" (Closed) Base URL: https://chromium.googlesource.com/chromium/deps/libmtp@master
Patch Set: Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « examples/Makefile.in ('k') | examples/albums.c » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: examples/albumart.c
diff --git a/examples/albumart.c b/examples/albumart.c
index 350ba4507d98917228742edbffa73cb461014488..c98b305086dfd944fc6100961f637853f25eac96 100644
--- a/examples/albumart.c
+++ b/examples/albumart.c
@@ -55,7 +55,6 @@ int main (int argc, char **argv) {
struct stat statbuff;
uint32_t storageid = 0;
uint32_t parentid = 0;
- int ret;
fprintf(stdout, "libmtp version: " LIBMTP_VERSION_STRING "\n\n");
@@ -125,8 +124,7 @@ int main (int argc, char **argv) {
return 1;
}
else {
- ret = read(fd, imagedata, filesize);
- if (ret == -1) perror("read");
+ read(fd, imagedata, filesize);
close(fd);
}
@@ -148,8 +146,7 @@ int main (int argc, char **argv) {
album->tracks = ids;
album->parent_id = parentid;
album->storage_id = storageid;
-
- ret = LIBMTP_Create_New_Album(device,album);
+ int ret = LIBMTP_Create_New_Album(device,album);
if (ret == 0) {
ret = LIBMTP_Send_Representative_Sample(device,album->album_id, albumart);
if (ret != 0) {
« no previous file with comments | « examples/Makefile.in ('k') | examples/albums.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698