All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/2] wic: plugins: rawcopy: Fixed wrong variable type
@ 2017-03-07 13:41 Daniel Schultz
  2017-03-07 13:41 ` [PATCH 2/2] wic: filemap: Fixed spared_copy skip Daniel Schultz
  0 siblings, 1 reply; 2+ messages in thread
From: Daniel Schultz @ 2017-03-07 13:41 UTC (permalink / raw)
  To: openembedded-core

Without the int() function this variable will be a string. This will led
to a error in Filemap on line 545 due wrong types.

> [...]
>   File
> ".../poky/scripts/lib/wic/filemap.py", line 545, in sparse_copy
>     if start < skip < end:
> TypeError: unorderable types: int() < str()

Signed-off-by: Daniel Schultz <d.schultz@phytec.de>
---
 scripts/lib/wic/plugins/source/rawcopy.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/lib/wic/plugins/source/rawcopy.py b/scripts/lib/wic/plugins/source/rawcopy.py
index 5bd22fd..618dd44 100644
--- a/scripts/lib/wic/plugins/source/rawcopy.py
+++ b/scripts/lib/wic/plugins/source/rawcopy.py
@@ -71,7 +71,7 @@ class RawCopyPlugin(SourcePlugin):
         dst = os.path.join(cr_workdir, "%s.%s" % (source_params['file'], part.lineno))
 
         if 'skip' in source_params:
-            sparse_copy(src, dst, skip=source_params['skip'])
+            sparse_copy(src, dst, skip=int(source_params['skip']))
         else:
             sparse_copy(src, dst)
 
-- 
1.9.1



^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-03-07 13:47 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-03-07 13:41 [PATCH 1/2] wic: plugins: rawcopy: Fixed wrong variable type Daniel Schultz
2017-03-07 13:41 ` [PATCH 2/2] wic: filemap: Fixed spared_copy skip Daniel Schultz

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.